5 #include <gtkmm/drawingarea.h>
6 #include <gtkmm/spinbutton.h>
7 #include <gtkmm/stock.h>
10 #include <libglademm.h>
11 #include <gtkmm/entry.h>
12 #include "itemptywnd.h"
16 class CItem:public Gtk::DrawingArea {
19 CItem(const char *filename);
21 virtual bool on_expose_event(GdkEventExpose* event);
22 virtual void on_menu_popup_propiedades();
23 virtual void on_menu_popup_rotar();
24 virtual void on_menu_popup_eliminar();
25 virtual void on_menu_popup_conectar();
26 Glib::RefPtr<Gdk::Pixbuf> get_image() { return image; }
30 int get_conector_in();
31 int get_conector_out();
33 Glib::ustring get_name();
35 void set_position(int _x, int _y);
37 void set_caudal(double _caudal);
38 void set_name(Glib::ustring _name);
39 void set_conector_in(int _in);
40 void set_conector_out(int _out);
41 bool is_occupied_area(int _a, int _b);
42 bool is_other_connection_area(int _a, int _b);
43 virtual void save(FILE *archivo) = 0;
44 virtual bool check_connection()=0;
45 virtual bool is_connection_area(int _a, int _b)=0;
47 Gtk::Entry *combo_entry;
48 std::list<CItem *> *listaItems;
52 int ID, conector_in, conector_out;
56 Gtk::Image menu_image_delete, menu_image_rotar, menu_image_propiedades, menu_image_linea;
57 Glib::RefPtr<Gdk::Pixbuf> image;
58 ItemPtyWnd *property_wnd;