date-selector: turn into a entry
After making the date selector use the brand new date chooser widget, it is now time to make it an entry. This commit, then turns GcalDateSelector into a GtkEntry subclass, and add all the plumbing that is necessary to make it work as such. As a side effect, this commit adds rudimentary natural language support for parsing dates.
This commit is contained in:
@@ -1,14 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<interface>
|
||||
<requires lib="gtk+" version="3.12"/>
|
||||
<template class="GcalDateSelector" parent="GtkMenuButton">
|
||||
<property name="use_popover">True</property>
|
||||
<property name="popover">date_selector_popover</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="date_label">
|
||||
<property name="visible">True</property>
|
||||
</object>
|
||||
</child>
|
||||
<template class="GcalDateSelector" parent="GtkEntry">
|
||||
<property name="visible">True</property>
|
||||
<property name="width-chars">16</property>
|
||||
<property name="max-width-chars">16</property>
|
||||
<property name="secondary-icon-name">pan-down-symbolic</property>
|
||||
<signal name="icon-press" handler="icon_pressed_cb" object="GcalDateSelector" swapped="no"/>
|
||||
</template>
|
||||
<object class="GtkPopover" id="date_selector_popover">
|
||||
<property name="position">bottom</property>
|
||||
|
||||
Reference in New Issue
Block a user