pingus-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pingus-CVS] CVS: Games/Pingus/src/gui component.hxx,1.8,1.9 gui_manager


From: torangan
Subject: [Pingus-CVS] CVS: Games/Pingus/src/gui component.hxx,1.8,1.9 gui_manager.hxx,1.8,1.9 root_gui_manager.cxx,1.5,1.6 root_gui_manager.hxx,1.3,1.4 surface_button.hxx,1.2,1.3
Date: 23 Aug 2002 15:50:27 -0000

Update of /usr/local/cvsroot/Games/Pingus/src/gui
In directory dark:/tmp/cvs-serv21141/gui

Modified Files:
        component.hxx gui_manager.hxx root_gui_manager.cxx 
        root_gui_manager.hxx surface_button.hxx 
Log Message:
- added copy constructor/operator= or private declarations
- some cleanup


Index: component.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/gui/component.hxx,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- component.hxx       16 Aug 2002 13:03:36 -0000      1.8
+++ component.hxx       23 Aug 2002 15:49:55 -0000      1.9
@@ -31,26 +31,28 @@
   private:
 
   public:
+    Component () { }
+    
     virtual void draw () =0;
-    virtual void update (float delta) { if(delta);}
+    virtual void update (float delta) { UNUSED_ARG(delta);}
     
-    virtual bool is_at (int x, int y) { if(x); if (y); return false; }
+    virtual bool is_at (int x, int y) { UNUSED_ARG(x); UNUSED_ARG(y); return 
false; }
 
     // Events
     /** Gets issued once the primary button is pressed */
-    virtual void on_primary_button_press (int x, int y) { if(x); if (y); }
+    virtual void on_primary_button_press (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
     
     /** Gets issued once the primary button is released */
-    virtual void on_primary_button_release (int x, int y) { if(x); if (y); }
+    virtual void on_primary_button_release (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
 
-    virtual void on_secondary_button_press (int x, int y) { if(x); if (y); }
-    virtual void on_secondary_button_release (int x, int y) { if(x); if (y); }
+    virtual void on_secondary_button_press (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
+    virtual void on_secondary_button_release (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
 
     /** Gets emmited when a button is pressed and released over the
        same component */
-    virtual void on_primary_button_click (int x, int y) { if(x); if (y); }
+    virtual void on_primary_button_click (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
 
-    virtual void on_secondary_button_click (int x, int y) { if(x); if (y); }
+    virtual void on_secondary_button_click (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
 
     /** Emmitted when pointer enters the region of the component */
     virtual void on_pointer_enter () {}
@@ -60,7 +62,7 @@
 
     /** Emitted when the pointer moved, x and y are the new pointer
        coordinates */
-    virtual void on_pointer_move (int x, int y) { if(x); if (y); }
+    virtual void on_pointer_move (int x, int y) { UNUSED_ARG(x); 
UNUSED_ARG(y); }
 
     // status functions for use in the update() function
     /** return true if currently pressed */
@@ -69,6 +71,10 @@
     /** true if mouse is currently over, FIXME: these seem to be
        unimplementable without renaming on_pointer_enter() and wrapp them */
     bool pointer_over ();
+    
+  private:
+    Component (const Component&);
+    Component operator= (const Component&); 
   };
 }
 

Index: gui_manager.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/gui/gui_manager.hxx,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- gui_manager.hxx     17 Aug 2002 01:02:38 -0000      1.8
+++ gui_manager.hxx     23 Aug 2002 15:49:55 -0000      1.9
@@ -83,6 +83,10 @@
 
     Component* component_at (int x, int y);  
     virtual bool is_at (int x, int y);
+    
+  private:
+    GUIManager (const GUIManager&);
+    GUIManager operator= (const GUIManager&);
   };
 }
 

Index: root_gui_manager.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/gui/root_gui_manager.cxx,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- root_gui_manager.cxx        14 Aug 2002 12:45:02 -0000      1.5
+++ root_gui_manager.cxx        23 Aug 2002 15:49:55 -0000      1.6
@@ -20,6 +20,7 @@
 #include <iostream>
 #include <list>
 #include "root_gui_manager.hxx"
+#include "../input/controller.hxx"
 
 using namespace GUI;
 using namespace Input;
@@ -41,7 +42,7 @@
   //GUIManager::update (delta);
   //process_input (controller->get_events ());
   
-  if (delta);
+  UNUSED_ARG(delta);
 }
 
 /* EOF */

Index: root_gui_manager.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/gui/root_gui_manager.hxx,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- root_gui_manager.hxx        30 Jul 2002 01:58:16 -0000      1.3
+++ root_gui_manager.hxx        23 Aug 2002 15:49:55 -0000      1.4
@@ -20,9 +20,13 @@
 #ifndef HEADER_PINGUS_GUI_ROOT_GUI_MANAGER_HXX
 #define HEADER_PINGUS_GUI_ROOT_GUI_MANAGER_HXX
 
-#include "../input/controller.hxx"
 #include "gui_manager.hxx"
 
+namespace Input
+{
+  class Controller;
+}
+
 namespace GUI
 {
   /** Root GUI manager 
@@ -37,6 +41,10 @@
     ~RootGUIManager ();
     
     void update (float delta);
+    
+  private:
+    RootGUIManager (const RootGUIManager&);
+    RootGUIManager operator= (const RootGUIManager&);
   };
 }
 

Index: surface_button.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/gui/surface_button.hxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- surface_button.hxx  2 Aug 2002 22:55:19 -0000       1.2
+++ surface_button.hxx  23 Aug 2002 15:49:55 -0000      1.3
@@ -56,6 +56,10 @@
 
     void on_pointer_enter ();
     void on_pointer_leave ();
+    
+  private:
+    SurfaceButton (const SurfaceButton&);
+    SurfaceButton operator= (const SurfaceButton&);
   };
 }
 





reply via email to

[Prev in Thread] Current Thread [Next in Thread]