[gnome-control-center] user-accounts: Make the "Account Activity" dialog wider



commit 079928d6931dd7f8bbbb01d4e35d5cb5528189bd
Author: Felipe Borges <felipeborges gnome org>
Date:   Wed Jul 13 18:57:54 2016 +0200

    user-accounts: Make the "Account Activity" dialog wider
    
    Set it to 60% of the parent window.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=767065

 panels/user-accounts/um-history-dialog.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/panels/user-accounts/um-history-dialog.c b/panels/user-accounts/um-history-dialog.c
index 67fd90e..7c5f45b 100644
--- a/panels/user-accounts/um-history-dialog.c
+++ b/panels/user-accounts/um-history-dialog.c
@@ -324,6 +324,7 @@ um_history_dialog_show (UmHistoryDialog *um,
                         GtkWindow       *parent)
 {
         GDateTime *temp, *local;
+        gint parent_width;
 
         if (um->week)
                 g_date_time_unref (um->week);
@@ -343,6 +344,8 @@ um_history_dialog_show (UmHistoryDialog *um,
 
         show_week (um);
 
+        gtk_window_get_size (parent, &parent_width, NULL);
+        gtk_window_set_default_size (GTK_WINDOW (um->dialog), parent_width * 0.6, -1);
         gtk_window_set_transient_for (GTK_WINDOW (um->dialog), parent);
         gtk_window_present (GTK_WINDOW (um->dialog));
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]