edit-dialog: Make it a HdyDialog subclass
This commit is contained in:
@@ -81,6 +81,7 @@ assert(cc.has_function('strerror'), '"strerror" not found')
|
||||
|
||||
# options
|
||||
config_h.set('ENABLE_TRACING', enable_tracing)
|
||||
config_h.set('HANDY_USE_UNSTABLE_API', true)
|
||||
|
||||
# _NL_TIME_FIRST_WEEKDAY is an enum and not a define
|
||||
nl_time_first_weekday_src = '''
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
|
||||
struct _GcalEditDialog
|
||||
{
|
||||
GtkDialog parent;
|
||||
HdyDialog parent;
|
||||
|
||||
gboolean writable;
|
||||
|
||||
@@ -134,7 +134,7 @@ static void on_remove_alarm_button_clicked (GtkButton
|
||||
static void on_add_alarm_button_clicked_cb (GtkWidget *button,
|
||||
GcalEditDialog *self);
|
||||
|
||||
G_DEFINE_TYPE (GcalEditDialog, gcal_edit_dialog, GTK_TYPE_DIALOG)
|
||||
G_DEFINE_TYPE (GcalEditDialog, gcal_edit_dialog, HDY_TYPE_DIALOG)
|
||||
|
||||
enum
|
||||
{
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#include "gcal-event.h"
|
||||
#include "gcal-manager.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <handy.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
@@ -32,7 +32,7 @@ G_BEGIN_DECLS
|
||||
|
||||
#define GCAL_TYPE_EDIT_DIALOG (gcal_edit_dialog_get_type ())
|
||||
|
||||
G_DECLARE_FINAL_TYPE (GcalEditDialog, gcal_edit_dialog, GCAL, EDIT_DIALOG, GtkDialog);
|
||||
G_DECLARE_FINAL_TYPE (GcalEditDialog, gcal_edit_dialog, GCAL, EDIT_DIALOG, HdyDialog);
|
||||
|
||||
GtkWidget* gcal_edit_dialog_new (void);
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<interface>
|
||||
<template class="GcalEditDialog" parent="GtkDialog">
|
||||
<template class="GcalEditDialog" parent="HdyDialog">
|
||||
<property name="can_focus">False</property>
|
||||
<property name="resizable">False</property>
|
||||
<property name="modal">True</property>
|
||||
|
||||
Reference in New Issue
Block a user