]> git.llucax.com Git - z.facultad/75.42/plaqui.git/blobdiff - Constructor/conduct.cpp
Creo que esto va a ser presentable para maniana. Luca si podes dale esto a Gonzalo...
[z.facultad/75.42/plaqui.git] / Constructor / conduct.cpp
index 075f645e264060a3638f30fbb56b77455b8d263c..a28aa7923b1303a053f729f00792598218b89852 100644 (file)
@@ -8,6 +8,15 @@ Conduct::Conduct()
        imgActual = 0;
        image = imageN;
        set_size_request(image->get_width(), image->get_height());
+       
+       Glib::RefPtr<Gnome::Glade::Xml> ref;
+       try {
+               ref = Gnome::Glade::Xml::create("constructor.glade", "conduct_pty_wnd");
+       }
+       catch(const Gnome::Glade::XmlError &ex) {
+               std::cerr << ex.what() << std::endl;
+       }
+       ref->get_widget_derived("conduct_pty_wnd",property_wnd);
 }
 
 Conduct::~Conduct()
@@ -37,6 +46,10 @@ bool Conduct::on_button_press_event(GdkEventButton *event)
                menu_popup.popup(event->button, event->time);
                 return true; //It has been handled.
        }
+       
+       if ((event->type == GDK_2BUTTON_PRESS) && (event->button ==1)){
+                       property_wnd->show();
+       }
        return true;
 }
 
@@ -47,3 +60,11 @@ void Conduct::on_menu_popup_rotar()
                event.button = 2;
        Conduct::on_button_press_event(&event);
 }
+
+void Conduct::on_menu_popup_propiedades()
+{
+       GdkEventButton event;
+       event.type = GDK_2BUTTON_PRESS;
+       event.button = 1;
+       Conduct::on_button_press_event(&event);
+}