glom r1509 - in trunk: . glom glom/utility_widgets/db_adddel



Author: murrayc
Date: Tue Apr  1 16:53:29 2008
New Revision: 1509
URL: http://svn.gnome.org/viewvc/glom?rev=1509&view=rev

Log:
2008-04-01  Murray Cumming  <murrayc murrayc com>

* glom/glom_privs.cc: Fixed the build (my previous changes did not 
actually compile).

Modified:
   trunk/ChangeLog
   trunk/glom/glom_privs.cc
   trunk/glom/utility_widgets/db_adddel/glom_db_treemodel.cc

Modified: trunk/glom/glom_privs.cc
==============================================================================
--- trunk/glom/glom_privs.cc	(original)
+++ trunk/glom/glom_privs.cc	Tue Apr  1 16:53:29 2008
@@ -20,6 +20,7 @@
 
 #include "glom_privs.h"
 #include <glom/libglom/standard_table_prefs_fields.h>
+#include <glom/application.h>
 
 namespace Glom
 {
@@ -46,7 +47,7 @@
 
 Privs::type_vecStrings Privs::get_database_users(const Glib::ustring& group_name)
 {
-  Bakery::BusyCursor cursor(get_app_window());
+  Bakery::BusyCursor cursor(App_Glom::get_application());
 
   type_vecStrings result;
 
@@ -320,7 +321,7 @@
   //TODO_Performance: There's lots of database access here.
   //We could maybe replace some with the postgres has_table_* function().
 
-  Bakery::BusyCursor cursor(get_app_window());
+  Bakery::BusyCursor cursor(App_Glom::get_application());
 
   Privileges result;
 

Modified: trunk/glom/utility_widgets/db_adddel/glom_db_treemodel.cc
==============================================================================
--- trunk/glom/utility_widgets/db_adddel/glom_db_treemodel.cc	(original)
+++ trunk/glom/utility_widgets/db_adddel/glom_db_treemodel.cc	Tue Apr  1 16:53:29 2008
@@ -710,6 +710,7 @@
   {
     //Get the current row:
     type_datamodel_iter row_iter = get_datamodel_row_iter_from_tree_row_iter(iter);
+    //std::cout << "DbTreeModel::iter_next_vfunc():" << row_iter << std::endl;
 
     //Make the iter_next GtkTreeIter represent the next row:
     ++row_iter;
@@ -820,12 +821,14 @@
 
   //TODO_Performance:
   //Get the number of non-removed items before this iter, because the path index doesn't care about removed internal stuff.
-  int path_index = -1 ;
-  if(row_iter > 0) //A row inedx of 0 must mean a path index ir there are _any_ non-removed rows.
-  for(type_datamodel_iter i = 0; i <= row_iter; ++i)
+  int path_index = -1;
+  if(row_iter > 0) //A row index of 0 must mean a path index if there are _any_ non-removed rows.
   {
-    if(!(m_map_rows[i].m_removed))
-      ++path_index;
+    for(type_datamodel_iter i = 0; i <= row_iter; ++i)
+    {
+      if(!(m_map_rows[i].m_removed))
+        ++path_index;
+    }
   }
 
   //g_warning("DbTreeModel::get_path_vfunc(): returning path index %d for internal row %d", path_index, row_iter);



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