diff options
author | Corey Berla <corey@berla.me> | 2023-04-10 17:58:09 -0700 |
---|---|---|
committer | Corey Berla <corey@berla.me> | 2023-04-10 18:02:35 -0700 |
commit | 2a70093a309481cf633086a5e8f0c8bc6d2c89f0 (patch) | |
tree | 73c1f95c5c0927ce33a203d7bf3bf8f89b138c32 /gtk/ui | |
parent | dd407dab000dc4de7d078c6270c93d303a1c18c6 (diff) | |
download | gtk+-2a70093a309481cf633086a5e8f0c8bc6d2c89f0.tar.gz |
filechooser: Set date and time after cell is a child of filechooserwidget
The date/time column relies on the filechooserwidget to format the date
properly. During bind, the filechoosercell, get the filechooserwidget
ancestor, but now due to changes in the listview, the cell isn't a
child of the filechooserwidget at that point. Since this is deeply
ingrained into the filechooserwidget, let's keep the same behavior,
but move it to filechoosercell in realize. Alternatively, we could have
used a signal factory (with the file chooser widget as the user data),
but that would have been a major overhaul.
Diffstat (limited to 'gtk/ui')
-rw-r--r-- | gtk/ui/gtkfilechooserwidget.ui | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/gtk/ui/gtkfilechooserwidget.ui b/gtk/ui/gtkfilechooserwidget.ui index c3f193973b..acc3b57e94 100644 --- a/gtk/ui/gtkfilechooserwidget.ui +++ b/gtk/ui/gtkfilechooserwidget.ui @@ -378,6 +378,7 @@ <lookup name="item">GtkColumnViewCell</lookup> </binding> <property name="list-item">GtkColumnViewCell</property> + <property name="date-column">true</property> <child> <object class="GtkBox"> <property name="spacing">6</property> @@ -388,21 +389,11 @@ </binding> <child> <object class="GtkLabel"> - <binding name="label"> - <closure type="gchararray" function="column_view_get_file_date"> - <lookup name="item">GtkColumnViewCell</lookup> - </closure> - </binding> </object> </child> <child> <object class="GtkLabel"> <property name="visible" bind-source="file_chooser_cell" bind-property="show-time" bind-flags="sync-create"/> - <binding name="label"> - <closure type="gchararray" function="column_view_get_file_time"> - <lookup name="item">GtkColumnViewCell</lookup> - </closure> - </binding> </object> </child> </object> |