frames: Disable the titlebar "inner resize"

Since invisible draggable borders have been around, there isn't really a big
need for this feature

https://bugzilla.gnome.org/show_bug.cgi?id=660129
This commit is contained in:
Jasper St. Pierre 2011-10-04 20:00:59 -04:00
parent 6aa4bfd060
commit d624e85bc1

View File

@ -2637,7 +2637,6 @@ control_rect (MetaFrameControl control,
return rect; return rect;
} }
#define RESIZE_EXTENDS 15
#define TOP_RESIZE_HEIGHT 4 #define TOP_RESIZE_HEIGHT 4
static MetaFrameControl static MetaFrameControl
get_control (MetaFrames *frames, get_control (MetaFrames *frames,
@ -2726,8 +2725,8 @@ get_control (MetaFrames *frames,
* in case of overlap. * in case of overlap.
*/ */
if (y >= (fgeom.height - fgeom.borders.total.bottom - RESIZE_EXTENDS) && if (y >= (fgeom.height - fgeom.borders.total.bottom) &&
x >= (fgeom.width - fgeom.borders.total.right - RESIZE_EXTENDS)) x >= (fgeom.width - fgeom.borders.total.right))
{ {
if (has_vert && has_horiz) if (has_vert && has_horiz)
return META_FRAME_CONTROL_RESIZE_SE; return META_FRAME_CONTROL_RESIZE_SE;
@ -2736,8 +2735,8 @@ get_control (MetaFrames *frames,
else if (has_horiz) else if (has_horiz)
return META_FRAME_CONTROL_RESIZE_E; return META_FRAME_CONTROL_RESIZE_E;
} }
else if (y >= (fgeom.height - fgeom.borders.total.bottom - RESIZE_EXTENDS) && else if (y >= (fgeom.height - fgeom.borders.total.bottom) &&
x <= (fgeom.borders.total.left + RESIZE_EXTENDS)) x <= fgeom.borders.total.left)
{ {
if (has_vert && has_horiz) if (has_vert && has_horiz)
return META_FRAME_CONTROL_RESIZE_SW; return META_FRAME_CONTROL_RESIZE_SW;
@ -2746,8 +2745,8 @@ get_control (MetaFrames *frames,
else if (has_horiz) else if (has_horiz)
return META_FRAME_CONTROL_RESIZE_W; return META_FRAME_CONTROL_RESIZE_W;
} }
else if (y < (fgeom.borders.invisible.top + RESIZE_EXTENDS) && else if (y < (fgeom.borders.invisible.top) &&
x <= (fgeom.borders.total.left + RESIZE_EXTENDS) && has_north_resize) x <= fgeom.borders.total.left && has_north_resize)
{ {
if (has_vert && has_horiz) if (has_vert && has_horiz)
return META_FRAME_CONTROL_RESIZE_NW; return META_FRAME_CONTROL_RESIZE_NW;
@ -2756,8 +2755,8 @@ get_control (MetaFrames *frames,
else if (has_horiz) else if (has_horiz)
return META_FRAME_CONTROL_RESIZE_W; return META_FRAME_CONTROL_RESIZE_W;
} }
else if (y < (fgeom.borders.invisible.top + RESIZE_EXTENDS) && else if (y < (fgeom.borders.invisible.top) &&
x >= (fgeom.width - fgeom.borders.total.right - RESIZE_EXTENDS) && has_north_resize) x >= fgeom.width - fgeom.borders.total.right && has_north_resize)
{ {
if (has_vert && has_horiz) if (has_vert && has_horiz)
return META_FRAME_CONTROL_RESIZE_NE; return META_FRAME_CONTROL_RESIZE_NE;
@ -2771,17 +2770,17 @@ get_control (MetaFrames *frames,
if (has_vert && has_north_resize) if (has_vert && has_north_resize)
return META_FRAME_CONTROL_RESIZE_N; return META_FRAME_CONTROL_RESIZE_N;
} }
else if (y >= (fgeom.height - fgeom.borders.total.bottom - RESIZE_EXTENDS)) else if (y >= (fgeom.height - fgeom.borders.total.bottom))
{ {
if (has_vert) if (has_vert)
return META_FRAME_CONTROL_RESIZE_S; return META_FRAME_CONTROL_RESIZE_S;
} }
else if (x <= fgeom.borders.total.left + RESIZE_EXTENDS) else if (x <= fgeom.borders.total.left)
{ {
if (has_horiz) if (has_horiz)
return META_FRAME_CONTROL_RESIZE_W; return META_FRAME_CONTROL_RESIZE_W;
} }
else if (x >= (fgeom.width - fgeom.borders.total.right - RESIZE_EXTENDS)) else if (x >= (fgeom.width - fgeom.borders.total.right))
{ {
if (has_horiz) if (has_horiz)
return META_FRAME_CONTROL_RESIZE_E; return META_FRAME_CONTROL_RESIZE_E;