summaryrefslogtreecommitdiff
path: root/adw/src/private/dialog_p.cpp
blob: da19ddc7baa816e83f694ddeb69b253c54d51d24 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#include "adwaitamm/private/dialog_p.hpp"

#include "adwaitamm/dialog.hpp"

#include <glibmm/class.h>
#include <glibmm/object.h>

#include <gtkmm/object.h>
#include <gtkmm/private/widget_p.h>
#include <gtkmm/shortcutmanager.h>

#include <adwaita.h>

namespace Adwaita
{
  auto Dialog_Class::init() -> Glib::Class const &
  {
    if (!gtype_)
    {
      class_init_func_ = &class_init_function;
      register_derived_type(adw_dialog_get_type());
      Gtk::ShortcutManager::add_interface(get_type());
    }
    return *this;
  }

  auto Dialog_Class::class_init_function(void * gclass, void * data) -> void
  {
    auto const klass = static_cast<BaseClassType *>(gclass);
    CppClassParent::class_init_function(klass, data);
  }

  auto Dialog_Class::wrap_new(GObject * object) -> Glib::ObjectBase *
  {
    return Gtk::manage(new Dialog(ADW_DIALOG(object)));
  }
}  // namespace Adwaita