Closed Bug 180134 Opened 22 years ago Closed 21 years ago

NS_METHOD nsWindow::ConstrainPosition needs impelentation in BeOS

Categories

(Core :: XUL, defect)

x86
BeOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: sergei_d, Assigned: beos)

Details

Attachments

(1 file, 1 obsolete file)

BeZilla users frequently complain about sitation when browser goes in
fullscreen-like state (but F11 don't work), so they should remove localstore.rdf
to restore normal size and position.
taking
Status: NEW → ASSIGNED
taking
Assignee: jaggernaut → arougthopher
Status: ASSIGNED → NEW
Status: NEW → ASSIGNED
Attached patch implement constrainposition (obsolete) — Splinter Review
ConstrainPosition implementation
Comment on attachment 119927 [details] [diff] [review]
implement constrainposition

Sergei, can you review this?
Attachment #119927 - Flags: review?(sergei_d)
That's good you proposed this. My current implementation of method was much simpler:

{
  if (eWindowType_dialog != mWindowType && eWindowType_toplevel != mWindowType)
    return NS_OK;
  if(*aX <=0)
    *aX=2;
  if(*aY <=0)
    *aY=20;
  return NS_OK;
}
Probably your version is more intelligent. Will try it
this is based on the gtk version, and also uses the allowSlop boolean passed in
Attached patch updated patchSplinter Review
Updated patch:
- Takes into account window borders and the title bar 
  - these values are defined as constants, since BeOS does not provide them
  - the title bar height is the height of the tallest title bar under BeOS
    (that I can find)
- Only deals with dialogs and windows now
Attachment #119927 - Attachment is obsolete: true
Attachment #119927 - Flags: review?(sergei_d)
Attachment #120041 - Flags: review?(sergei_d)
Paul, it seems something happened when you created last patch, and it misses now
 both declaration of mIsTopWidgetWindow (nsWindow.h) and assignment of  values
to it, initiall, and real (nsWindow.cpp)
Another notice Paul, what do you think about changing style from

foo {
}

to 

foo
{
}

everywhere in BeOS code?
Personally i can't stand first style...
nope, that variable existed before my original patch, but was never used.  So 
I, since it was set the same way as the windows port, I backed out my "new" 
variable, and am using the previously "unused" variable.

as far as style changes, personally, I don't care.  I can read the code either 
way.  I usually write my code using the first style, because I'm a java dev :-
)  But, that doesn't mean i have to.
Comment on attachment 120041 [details] [diff] [review]
updated patch

Works well here, reviewing
Attachment #120041 - Flags: review?(sergei_d) → review+
this has been checked in
Status: ASSIGNED → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: