[glom] Canvas_PrintLayout: Fix typo to pass the item by reference.



commit a550faf329bc331903732bf3374a479850289be0
Author: Murray Cumming <murrayc murrayc com>
Date:   Sat Aug 6 19:14:40 2011 +0200

    Canvas_PrintLayout: Fix typo to pass the item by reference.
    
    * glom/print_layout/canvas_print_layout.[h|cc]:
    add_canvas_layout_item(): Add a missing & to the parameter.

 ChangeLog                                |    7 +++++++
 glom/print_layout/canvas_print_layout.cc |    2 +-
 glom/print_layout/canvas_print_layout.h  |    2 +-
 3 files changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 1e813c9..323b365 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2011-08-06  Murray Cumming  <murrayc murrayc com>
 
+	Canvas_PrintLayout: Fix typo to pass the item by reference.
+
+	* glom/print_layout/canvas_print_layout.[h|cc]: 
+	add_canvas_layout_item(): Add a missing & to the parameter.
+
+2011-08-06  Murray Cumming  <murrayc murrayc com>
+
 	Print Layout: Implement cut/copy/paste/delete.
 
 	* glom/mode_design/print_layouts/window_print_layout_edit.[h|cc]:
diff --git a/glom/print_layout/canvas_print_layout.cc b/glom/print_layout/canvas_print_layout.cc
index 6dcb723..3b25602 100644
--- a/glom/print_layout/canvas_print_layout.cc
+++ b/glom/print_layout/canvas_print_layout.cc
@@ -153,7 +153,7 @@ void Canvas_PrintLayout::add_layout_group_children(const sharedptr<LayoutGroup>&
   m_modified = true;
 }
 
-void Canvas_PrintLayout::add_canvas_layout_item(const Glib::RefPtr<CanvasLayoutItem> item) //TODO: Pass by ref.
+void Canvas_PrintLayout::add_canvas_layout_item(const Glib::RefPtr<CanvasLayoutItem>& item)
 {
   if(!item)
     return;
diff --git a/glom/print_layout/canvas_print_layout.h b/glom/print_layout/canvas_print_layout.h
index 5009f77..f50ffd8 100644
--- a/glom/print_layout/canvas_print_layout.h
+++ b/glom/print_layout/canvas_print_layout.h
@@ -57,7 +57,7 @@ public:
   void hide_page_bounds();
 
   //Override: TODO: Is it really?
-  void add_canvas_layout_item(const Glib::RefPtr<CanvasLayoutItem> item);
+  void add_canvas_layout_item(const Glib::RefPtr<CanvasLayoutItem>& item);
 
   void remove_canvas_layout_item(const Glib::RefPtr<CanvasLayoutItem>& item);
 



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