]> git.llucax.com Git - z.facultad/75.42/plaqui.git/blobdiff - Constructor/src/pump.cpp
* Se agrega carga de una planta desde un XML (Archivo->Abrir)
[z.facultad/75.42/plaqui.git] / Constructor / src / pump.cpp
index 629f3924fe0786512242c2b389b69f51b06fe9e0..e2510f6081279d2ca4bf2139bb303d36652f7375 100644 (file)
@@ -1,13 +1,20 @@
 #include "pump.h"
 #include "pumpptywnd.h"
 
 #include "pump.h"
 #include "pumpptywnd.h"
 
-Pump::Pump()
+Pump::Pump(int orientacion)
 {
        imageE = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_e.png");
        imageO = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_o.png");
        null = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_null.png");
 {
        imageE = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_e.png");
        imageO = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_o.png");
        null = Gdk::Pixbuf::create_from_file(PACKAGE_DATA_DIR"/plaqui-constructor/pixmaps/bomba_null.png");
-       imgActual = 0;
-       image = imageE;
+       imgActual = orientacion;
+       switch (imgActual) {
+               case 1:
+                       image = imageO;
+                       break;
+               default: 
+                       imgActual = 0;
+                       image = imageE;                 
+       }
        set_size_request(image->get_width(), image->get_height());
 
        Glib::RefPtr<Gnome::Glade::Xml> ref = Gnome::Glade::Xml::create(PACKAGE_DATA_DIR"/plaqui-constructor/dialogs/constructor.glade", "pump_pty_wnd");
        set_size_request(image->get_width(), image->get_height());
 
        Glib::RefPtr<Gnome::Glade::Xml> ref = Gnome::Glade::Xml::create(PACKAGE_DATA_DIR"/plaqui-constructor/dialogs/constructor.glade", "pump_pty_wnd");