Fixed the window strut
This commit is contained in:
parent
3a5bc68cc2
commit
04d833ba37
34
po/fr.po
34
po/fr.po
@ -7,7 +7,7 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Panel 0.0.5\n"
|
"Project-Id-Version: Panel 0.0.5\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2011-10-28 00:15+0200\n"
|
"POT-Creation-Date: 2011-10-28 00:40+0200\n"
|
||||||
"PO-Revision-Date: 2010-04-22 12:45+0200\n"
|
"PO-Revision-Date: 2010-04-22 12:45+0200\n"
|
||||||
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
|
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
|
||||||
"Language-Team: French\n"
|
"Language-Team: French\n"
|
||||||
@ -21,7 +21,7 @@ msgstr ""
|
|||||||
msgid "Unknown"
|
msgid "Unknown"
|
||||||
msgstr "Inconnu"
|
msgstr "Inconnu"
|
||||||
|
|
||||||
#: ../src/applets/battery.c:185 ../src/panel.c:457 ../src/panel.c:462
|
#: ../src/applets/battery.c:185 ../src/panel.c:454 ../src/panel.c:459
|
||||||
#: ../src/run.c:214 ../src/run.c:220
|
#: ../src/run.c:214 ../src/run.c:220
|
||||||
msgid "Error"
|
msgid "Error"
|
||||||
msgstr "Erreur"
|
msgstr "Erreur"
|
||||||
@ -88,8 +88,8 @@ msgstr "Verrouiller l'écran"
|
|||||||
msgid "Logging out is disabled"
|
msgid "Logging out is disabled"
|
||||||
msgstr "Se déconnecter est désactivé"
|
msgstr "Se déconnecter est désactivé"
|
||||||
|
|
||||||
#: ../src/applets/logout.c:69 ../src/panel.c:1321 ../src/panel.c:1328
|
#: ../src/applets/logout.c:69 ../src/panel.c:1318 ../src/panel.c:1325
|
||||||
#: ../src/panel.c:1337
|
#: ../src/panel.c:1334
|
||||||
msgid "Logout"
|
msgid "Logout"
|
||||||
msgstr "Déconnexion"
|
msgstr "Déconnexion"
|
||||||
|
|
||||||
@ -195,35 +195,35 @@ msgstr "Petite"
|
|||||||
msgid "Smaller"
|
msgid "Smaller"
|
||||||
msgstr "Très petite"
|
msgstr "Très petite"
|
||||||
|
|
||||||
#: ../src/panel.c:574
|
#: ../src/panel.c:571
|
||||||
msgid "Panel preferences"
|
msgid "Panel preferences"
|
||||||
msgstr "Préférences du Panel"
|
msgstr "Préférences du Panel"
|
||||||
|
|
||||||
#: ../src/panel.c:588
|
#: ../src/panel.c:585
|
||||||
msgid "General"
|
msgid "General"
|
||||||
msgstr "Général"
|
msgstr "Général"
|
||||||
|
|
||||||
#: ../src/panel.c:617
|
#: ../src/panel.c:614
|
||||||
msgid "Applets:"
|
msgid "Applets:"
|
||||||
msgstr "Greffons :"
|
msgstr "Greffons :"
|
||||||
|
|
||||||
#: ../src/panel.c:692
|
#: ../src/panel.c:689
|
||||||
msgid "Top panel:"
|
msgid "Top panel:"
|
||||||
msgstr "Panneau supérieur :"
|
msgstr "Panneau supérieur :"
|
||||||
|
|
||||||
#: ../src/panel.c:698 ../src/panel.c:702 ../src/panel.c:733 ../src/panel.c:737
|
#: ../src/panel.c:695 ../src/panel.c:699 ../src/panel.c:730 ../src/panel.c:734
|
||||||
msgid "Default"
|
msgid "Default"
|
||||||
msgstr "Par défaut"
|
msgstr "Par défaut"
|
||||||
|
|
||||||
#: ../src/panel.c:727
|
#: ../src/panel.c:724
|
||||||
msgid "Bottom panel:"
|
msgid "Bottom panel:"
|
||||||
msgstr "Panneau inférieur :"
|
msgstr "Panneau inférieur :"
|
||||||
|
|
||||||
#: ../src/panel.c:1260
|
#: ../src/panel.c:1257
|
||||||
msgid "translator-credits"
|
msgid "translator-credits"
|
||||||
msgstr "Pierre Pronchery <khorben@defora.org>"
|
msgstr "Pierre Pronchery <khorben@defora.org>"
|
||||||
|
|
||||||
#: ../src/panel.c:1307
|
#: ../src/panel.c:1304
|
||||||
msgid ""
|
msgid ""
|
||||||
"This will log you out of the current session, therefore closing any "
|
"This will log you out of the current session, therefore closing any "
|
||||||
"application currently opened and losing any unsaved data.\n"
|
"application currently opened and losing any unsaved data.\n"
|
||||||
@ -234,7 +234,7 @@ msgstr ""
|
|||||||
"sauvegardées.\n"
|
"sauvegardées.\n"
|
||||||
"Voulez-vous continuer?"
|
"Voulez-vous continuer?"
|
||||||
|
|
||||||
#: ../src/panel.c:1423
|
#: ../src/panel.c:1420
|
||||||
msgid ""
|
msgid ""
|
||||||
"This will shutdown your device, therefore closing any application currently "
|
"This will shutdown your device, therefore closing any application currently "
|
||||||
"opened and losing any unsaved data.\n"
|
"opened and losing any unsaved data.\n"
|
||||||
@ -245,7 +245,7 @@ msgstr ""
|
|||||||
"sauvegardées.\n"
|
"sauvegardées.\n"
|
||||||
"Voulez-vous continuer?"
|
"Voulez-vous continuer?"
|
||||||
|
|
||||||
#: ../src/panel.c:1428
|
#: ../src/panel.c:1425
|
||||||
msgid ""
|
msgid ""
|
||||||
"This will shutdown your computer, therefore closing any application "
|
"This will shutdown your computer, therefore closing any application "
|
||||||
"currently opened and losing any unsaved data.\n"
|
"currently opened and losing any unsaved data.\n"
|
||||||
@ -256,11 +256,11 @@ msgstr ""
|
|||||||
"sauvegardées.\n"
|
"sauvegardées.\n"
|
||||||
"Voulez-vous continuer?"
|
"Voulez-vous continuer?"
|
||||||
|
|
||||||
#: ../src/panel.c:1442 ../src/panel.c:1449 ../src/panel.c:1458
|
#: ../src/panel.c:1439 ../src/panel.c:1446 ../src/panel.c:1455
|
||||||
msgid "Shutdown"
|
msgid "Shutdown"
|
||||||
msgstr "Arrêter"
|
msgstr "Arrêter"
|
||||||
|
|
||||||
#: ../src/panel.c:1448
|
#: ../src/panel.c:1445
|
||||||
msgid "Restart"
|
msgid "Restart"
|
||||||
msgstr "Redémarrer"
|
msgstr "Redémarrer"
|
||||||
|
|
||||||
@ -300,6 +300,6 @@ msgstr "Permissions insuffisantes"
|
|||||||
msgid "Usage: run\n"
|
msgid "Usage: run\n"
|
||||||
msgstr "Usage: run\n"
|
msgstr "Usage: run\n"
|
||||||
|
|
||||||
#: ../src/window.c:56
|
#: ../src/window.c:63
|
||||||
msgid "Invalid panel size"
|
msgid "Invalid panel size"
|
||||||
msgstr "Taille invalide pour le panel"
|
msgstr "Taille invalide pour le panel"
|
||||||
|
31
src/window.c
31
src/window.c
@ -38,6 +38,13 @@ struct _PanelWindow
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* prototypes */
|
||||||
|
static void _panel_window_reset(PanelWindow * panel, PanelPosition position,
|
||||||
|
GdkRectangle * rect);
|
||||||
|
static void _panel_window_reset_strut(PanelWindow * panel,
|
||||||
|
PanelPosition position, GdkRectangle * rect);
|
||||||
|
|
||||||
|
|
||||||
/* public */
|
/* public */
|
||||||
/* functions */
|
/* functions */
|
||||||
/* panel_window_new */
|
/* panel_window_new */
|
||||||
@ -76,8 +83,9 @@ PanelWindow * panel_window_new(PanelPosition position,
|
|||||||
panel->hbox = gtk_hbox_new(FALSE, 2);
|
panel->hbox = gtk_hbox_new(FALSE, 2);
|
||||||
gtk_container_add(GTK_CONTAINER(panel->window), panel->hbox);
|
gtk_container_add(GTK_CONTAINER(panel->window), panel->hbox);
|
||||||
gtk_container_set_border_width(GTK_CONTAINER(panel->window), 4);
|
gtk_container_set_border_width(GTK_CONTAINER(panel->window), 4);
|
||||||
panel_window_reset(panel, position, root);
|
_panel_window_reset(panel, position, root);
|
||||||
gtk_widget_show_all(panel->window);
|
gtk_widget_show_all(panel->window);
|
||||||
|
_panel_window_reset_strut(panel, position, root);
|
||||||
return panel;
|
return panel;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -114,11 +122,19 @@ void panel_window_append(PanelWindow * panel, GtkWidget * widget,
|
|||||||
|
|
||||||
|
|
||||||
/* panel_window_reset */
|
/* panel_window_reset */
|
||||||
static void _reset_strut(PanelWindow * panel, PanelPosition position,
|
|
||||||
GdkRectangle * root);
|
|
||||||
|
|
||||||
void panel_window_reset(PanelWindow * panel, PanelPosition position,
|
void panel_window_reset(PanelWindow * panel, PanelPosition position,
|
||||||
GdkRectangle * root)
|
GdkRectangle * root)
|
||||||
|
{
|
||||||
|
_panel_window_reset(panel, position, root);
|
||||||
|
_panel_window_reset_strut(panel, position, root);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* private */
|
||||||
|
/* functions */
|
||||||
|
/* panel_window_reset */
|
||||||
|
static void _panel_window_reset(PanelWindow * panel, PanelPosition position,
|
||||||
|
GdkRectangle * root)
|
||||||
{
|
{
|
||||||
gtk_window_resize(GTK_WINDOW(panel->window), root->width,
|
gtk_window_resize(GTK_WINDOW(panel->window), root->width,
|
||||||
panel->height);
|
panel->height);
|
||||||
@ -127,11 +143,12 @@ void panel_window_reset(PanelWindow * panel, PanelPosition position,
|
|||||||
else
|
else
|
||||||
gtk_window_move(GTK_WINDOW(panel->window), root->x,
|
gtk_window_move(GTK_WINDOW(panel->window), root->x,
|
||||||
root->y + root->height - panel->height);
|
root->y + root->height - panel->height);
|
||||||
_reset_strut(panel, position, root);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void _reset_strut(PanelWindow * panel, PanelPosition position,
|
|
||||||
GdkRectangle * root)
|
/* panel_window_reset_strut */
|
||||||
|
static void _panel_window_reset_strut(PanelWindow * panel,
|
||||||
|
PanelPosition position, GdkRectangle * root)
|
||||||
{
|
{
|
||||||
GdkWindow * window;
|
GdkWindow * window;
|
||||||
GdkAtom atom;
|
GdkAtom atom;
|
||||||
|
Loading…
Reference in New Issue
Block a user