diff options
| author | Dana Jansens <danakj@orodu.net> | 2008-02-06 23:47:38 -0500 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2008-02-07 02:14:44 -0500 |
| commit | f4838c9a3d9717a8d8bbf4fb94876dd4fc10f7da (patch) | |
| tree | e3ea1298f4a8a9714d4d10bfdcef45586e6a001d /openbox | |
| parent | 9a4ce94579bc7161d4ed55b20f00b3f76deff3e2 (diff) | |
position the buttons in the bottom right instead of centering them
Diffstat (limited to 'openbox')
| -rw-r--r-- | openbox/prompt.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/openbox/prompt.c b/openbox/prompt.c index b9183a9b..9263a040 100644 --- a/openbox/prompt.c +++ b/openbox/prompt.c @@ -261,13 +261,13 @@ static void prompt_layout(ObPrompt *self) self->msg.x = l + (w - self->msg.width) / 2; self->msg.y = t; - /* position the button buttons */ - buttonx = l + (w - allbuttonsw) / 2; - for (i = 0; i < self->n_buttons; ++i) { - self->button[i].x = buttonx; - buttonx += self->button[i].width + BUTTON_SEPARATION; - self->button[i].y = t + h - allbuttonsh; - self->button[i].y += (allbuttonsh - self->button[i].height) / 2; + /* position the button buttons on the right of the dialog */ + buttonx = l + w; + for (i = self->n_buttons; i > 0; --i) { + self->button[i-1].x = buttonx - self->button[i-1].width; + buttonx -= self->button[i-1].width + BUTTON_SEPARATION; + self->button[i-1].y = t + h - allbuttonsh; + self->button[i-1].y += (allbuttonsh - self->button[i-1].height) / 2; } /* size and position the toplevel window */ |
