/[svn]/gigedit/trunk/src/gigedit/dimensionmanager.h
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/dimensionmanager.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2579 by persson, Sat May 24 06:44:39 2014 UTC revision 3068 by schoenebeck, Mon Jan 2 22:13:01 2017 UTC
# Line 1  Line 1 
1  /*                                                         -*- c++ -*-  /*                                                         -*- c++ -*-
2   * Copyright (C) 2006, 2007 Andreas Persson   * Copyright (C) 2006 - 2017 Andreas Persson
3   *   *
4   * This program is free software; you can redistribute it and/or   * This program is free software; you can redistribute it and/or
5   * modify it under the terms of the GNU General Public License as   * modify it under the terms of the GNU General Public License as
# Line 21  Line 21 
21  #define GIGEDIT_DIMENSIONMANAGER_H  #define GIGEDIT_DIMENSIONMANAGER_H
22    
23  #include <glibmm/property.h>  #include <glibmm/property.h>
24    #include <gtkmm/box.h>
25  #include <gtkmm/window.h>  #include <gtkmm/window.h>
26  #include <gtkmm/layout.h>  #include <gtkmm/layout.h>
27  #include <gtkmm/button.h>  #include <gtkmm/button.h>
# Line 30  Line 31 
31  #include <gtkmm/scrolledwindow.h>  #include <gtkmm/scrolledwindow.h>
32  #include <gtkmm/checkbutton.h>  #include <gtkmm/checkbutton.h>
33    
34  #include <gig.h>  #ifdef LIBGIG_HEADER_FILE
35    # include LIBGIG_HEADER_FILE(gig.h)
36    #else
37    # include <gig.h>
38    #endif
39    
40  #include <set>  #include <set>
41    #include "ManagedWindow.h"
42    
43  class DimTypeCellRenderer : public Gtk::CellRendererText {  class DimTypeCellRenderer : public Gtk::CellRendererText {
44  public:  public:
# Line 70  private: Line 77  private:
77      Glib::Property<std::set<int> > m_propertyValue;      Glib::Property<std::set<int> > m_propertyValue;
78  };  };
79    
80  class DimensionManager : public Gtk::Window {  class DimensionManager : public ManagedWindow {
81  public:  public:
82      sigc::signal<void, gig::Region*> region_to_be_changed_signal;      sigc::signal<void, gig::Region*> region_to_be_changed_signal;
83      sigc::signal<void, gig::Region*> region_changed_signal;      sigc::signal<void, gig::Region*> region_changed_signal;
# Line 78  public: Line 85  public:
85      DimensionManager();      DimensionManager();
86      void show(gig::Region* region);      void show(gig::Region* region);
87      void set_region(gig::Region* region);      void set_region(gig::Region* region);
88    
89        // implementation for abstract methods of interface class "ManagedWindow"
90        virtual Settings::Property<int>* windowSettingX() { return &Settings::singleton()->dimensionManagerWindowX; }
91        virtual Settings::Property<int>* windowSettingY() { return &Settings::singleton()->dimensionManagerWindowY; }
92        virtual Settings::Property<int>* windowSettingWidth() { return &Settings::singleton()->dimensionManagerWindowW; }
93        virtual Settings::Property<int>* windowSettingHeight() { return &Settings::singleton()->dimensionManagerWindowH; }
94        
95  protected:  protected:
96      gig::Region* region;      gig::Region* region;
97      Gtk::VBox vbox;      Gtk::VBox vbox;
# Line 122  protected: Line 136  protected:
136      } comboModel;      } comboModel;
137    
138      Glib::RefPtr<Gtk::ListStore> refTableModel;      Glib::RefPtr<Gtk::ListStore> refTableModel;
139        bool ignoreColumnClicked; //HACK: Prevents that onColumnClicked() gets called multiple times or at times where it is not desired
140    
141      void onAllRegionsCheckBoxToggled();      void onAllRegionsCheckBoxToggled();
142        void onColumnClicked();
143      void refreshManager();      void refreshManager();
144      void addDimension();      void addDimension();
145      void removeDimension();      void removeDimension();

Legend:
Removed from v.2579  
changed lines
  Added in v.3068

  ViewVC Help
Powered by ViewVC