<action name="Resize"/>
</mousebind>
- <mousebind button="A-Middle" action="Press">
+ <mousebind button="A-Middle" action="Click">
<action name="Focus"/>
<action name="Lower"/>
</mousebind>
<mousebind button="A-Down" action="Click">
<action name="DesktopNext"/>
</mousebind>
+ <mousebind button="C-A-Up" action="Click">
+ <action name="DesktopPrevious"/>
+ </mousebind>
+ <mousebind button="C-A-Down" action="Click">
+ <action name="DesktopNext"/>
+ </mousebind>
<mousebind button="A-S-Up" action="Click">
<action name="SendToDesktopPrevious"/>
</mousebind>
<mousebind button="Middle" action="Press">
<action name="Focus"/>
+ </mousebind>
+ <mousebind button="Middle" action="Click">
<action name="Lower"/>
</mousebind>
<mousebind button="Middle" action="Press">
<action name="Focus"/>
+ </mousebind>
+ <mousebind button="Middle" action="Click">
<action name="Lower"/>
</mousebind>
<context name="Client">
<mousebind button="Left" action="Press">
<action name="Focus"/>
- <action name="Raise"/>
</mousebind>
<mousebind button="Middle" action="Press">
<action name="Focus"/>
- <action name="Raise"/>
</mousebind>
<mousebind button="Right" action="Press">
<action name="Focus"/>
- <action name="Raise"/>
</mousebind>
</context>
<mousebind button="A-Down" action="Press">
<action name="DesktopNext"/>
</mousebind>
+ <mousebind button="C-A-Up" action="Press">
+ <action name="DesktopPrevious"/>
+ </mousebind>
+ <mousebind button="C-A-Down" action="Press">
+ <action name="DesktopNext"/>
+ </mousebind>
<mousebind button="Left" action="Press">
<action name="Focus"/>
!self->iconic &&
/* this means focus=true for window is same as config_focus_new=true */
((config_focus_new || (settings && settings->focus == 1)) ||
- client_search_focus_parent(self)) &&
+ client_search_focus_tree_full(self)) &&
/* this checks for focus=false for the window */
(!settings || settings->focus != 0) &&
/* note the check against Type_Normal/Dialog, not client_normal(self),
(!self->positioned ? "no" :
(self->positioned == PPosition ? "program specified" :
(self->positioned == USPosition ? "user specified" :
- "BADNESS !?"))), self->area.x, self->area.y);
+ (self->positioned == PPosition | USPosition ?
+ "program + user specified" :
+ "BADNESS !?")))), self->area.x, self->area.y);
+
+ ob_debug("Sized: %s @ %d %d\n",
+ (!self->sized ? "no" :
+ (self->sized == PSize ? "program specified" :
+ (self->sized == USSize ? "user specified" :
+ (self->sized == PSize | USSize ?
+ "program + user specified" :
+ "BADNESS !?")))), self->area.width, self->area.height);
transient = place_client(self, &placex, &placey, settings);
the visible screen area on its monitor.
the monitor is chosen by place_client! */
- if (!(self->positioned & USPosition)) {
+ if (!(self->sized & USSize)) {
/* make a copy to modify */
Rect a = *screen_area_monitor(self->desktop, client_monitor(self));
"Not focusing the window because its on another "
"desktop\n");
}
- /* If something is focused, and it's not our parent... */
- else if (focus_client && client_search_focus_parent(self) == NULL)
+ /* If something is focused, and it's not our relative... */
+ else if (focus_client && client_search_focus_tree_full(self) == NULL)
{
/* If time stamp is old, don't steal focus */
if (self->user_time && last_time &&
"Not focusing the window because a globally "
"active client has focus\n");
}
+ /* Don't move focus if it's not going to go to this window
+ anyway */
+ else if (client_focus_target(self) != self) {
+ activate = FALSE;
+ ob_debug_type(OB_DEBUG_FOCUS,
+ "Not focusing the window because another window "
+ "would get the focus anyway\n");
+ }
}
if (!activate) {
self->frame = frame_new(self);
frame_adjust_area(self->frame, FALSE, TRUE, TRUE);
+ ob_debug("gave extents left %d right %d top %d bottom %d\n",
+ self->frame->size.left, self->frame->size.right,
+ self->frame->size.top, self->frame->size.bottom);
+
/* free the ObAppSettings shallow copy */
g_free(settings);
RECT_SET_POINT(self->area, self->session->x, self->session->y);
self->positioned = USPosition;
+ self->sized = USSize;
if (self->session->w > 0)
self->area.width = self->session->w;
if (self->session->h > 0)
if (!client_normal(self))
*/
self->positioned = (size.flags & (PPosition|USPosition));
+ self->sized = (size.flags & (PSize|USSize));
if (size.flags & PWinGravity)
self->gravity = size.win_gravity;
we only force it if it tries to go completely offscreen, if neither, we
should place the window ourselves when it first appears */
guint positioned;
+
+ /*! Was the window's size requested by the application or the user?
+ If by the application we don't let it go outside the available area */
+ guint sized;
/*! Can the window receive input focus? */
gboolean can_focus;
/* some elements are sized based of the width, so don't let them have
negative values */
self->width = MAX(self->width,
- (ob_rr_theme->grip_width + self->bwidth) * 2) + 1;
+ (ob_rr_theme->grip_width + self->bwidth) * 2 + 1);
STRUT_SET(self->size,
self->cbwidth_x + (!self->max_horz ? self->bwidth : 0),
if (!fake) {
if (self->bwidth) {
+ gint titlesides;
+
+ /* height of titleleft and titleright */
+ titlesides = (!self->max_horz ?
+ ob_rr_theme->grip_width :
+ self->size.top - self->bwidth);
+
XMoveResizeWindow(ob_display, self->titletop,
ob_rr_theme->grip_width + self->bwidth, 0,
/* width + bwidth*2 - bwidth*2 - grips*2 */
ob_rr_theme->grip_width + self->bwidth,
self->bwidth);
- XMoveResizeWindow(ob_display, self->titleleft,
- 0, self->bwidth,
- self->bwidth,
- (!self->max_horz ?
- ob_rr_theme->grip_width :
- self->size.top - self->bwidth));
- XMoveResizeWindow(ob_display, self->titleright,
- self->client->area.width +
- self->size.left + self->size.right -
- self->bwidth,
- self->bwidth,
- self->bwidth,
- (!self->max_horz ?
- ob_rr_theme->grip_width :
- self->size.top - self->bwidth));
+ if (titlesides > 0) {
+ XMoveResizeWindow(ob_display, self->titleleft,
+ 0, self->bwidth,
+ self->bwidth,
+ titlesides);
+ XMoveResizeWindow(ob_display, self->titleright,
+ self->client->area.width +
+ self->size.left + self->size.right -
+ self->bwidth,
+ self->bwidth,
+ self->bwidth,
+ titlesides);
+
+ XMapWindow(ob_display, self->titleleft);
+ XMapWindow(ob_display, self->titleright);
+ } else {
+ XUnmapWindow(ob_display, self->titleleft);
+ XUnmapWindow(ob_display, self->titleright);
+ }
XMapWindow(ob_display, self->titletop);
XMapWindow(ob_display, self->titletopleft);
XMapWindow(ob_display, self->titletopright);
- XMapWindow(ob_display, self->titleleft);
- XMapWindow(ob_display, self->titleright);
if (self->decorations & OB_FRAME_DECOR_TITLEBAR &&
self->rbwidth)
case Above:
ob_debug("Restack request Above for client %s sibling %s\n",
client->title, sibling ? sibling->title : "(all)");
- if (activate && !client->iconic)
+ if (activate && !client->iconic && client_normal(client))
/* use user=TRUE because it is impossible to get a timestamp
for this */
client_activate(client, FALSE, TRUE);
ob_debug("Restack request TopIf for client %s sibling %s\n",
client->title, sibling ? sibling->title : "(all)");
if (stacking_occluded(client, sibling)) {
- if (activate && !client->iconic)
+ if (activate && !client->iconic && client_normal(client))
/* use user=TRUE because it is impossible to get a timestamp
for this */
client_activate(client, FALSE, TRUE);
"%s\n",
client->title, sibling ? sibling->title : "(all)");
if (stacking_occluded(client, sibling)) {
- if (activate && !client->iconic)
+ if (activate && !client->iconic && client_normal(client))
/* use user=TRUE because it is impossible to get a timestamp
for this */
client_activate(client, FALSE, TRUE);
#: openbox/screen.c:946
#, c-format
msgid "desktop %i"
-msgstr "trabalho %i"
+msgstr "área de trabalho %i"
#: openbox/session.c:103
#, c-format
#: openbox/screen.c:946
#, c-format
msgid "desktop %i"
-msgstr "trabalho %i"
+msgstr "área de trabalho %i"
#: openbox/session.c:103
#, c-format