nemiver r673 - in trunk: . src/persp/dbgperspective



Author: jjongsma
Date: Thu Jan 10 03:00:52 2008
New Revision: 673
URL: http://svn.gnome.org/viewvc/nemiver?rev=673&view=rev

Log:
remove global variables configure option

	* configure.ac: remove --enable-global-variables configure option
	* src/persp/dbgperspective/nmv-local-vars-inspector2.cc: remove the global
	variables listing from the local variables widget.  It will be added later
	as a modal dialog.


Modified:
   trunk/ChangeLog
   trunk/configure.ac
   trunk/src/persp/dbgperspective/nmv-local-vars-inspector2.cc

Modified: trunk/configure.ac
==============================================================================
--- trunk/configure.ac	(original)
+++ trunk/configure.ac	Thu Jan 10 03:00:52 2008
@@ -182,20 +182,6 @@
     AC_MSG_NOTICE([disabled variable walker])
 fi
 
-ENABLE_GLOBAL_VARIABLES=no
-AC_ARG_ENABLE(global-variables,
-              AC_HELP_STRING([--enable-global-variables],
-                             [show global variables widget. default is disabled]),
-              ENABLE_GLOBAL_VARIABLES=$enableval,
-              ENABLE_GLOBAL_VARIABLES=no)
-
-if test x$ENABLE_GLOBAL_VARIABLES = xyes -a x$ENABLE_VARIABLE_WALKER = xyes; then
-    AC_DEFINE([WITH_GLOBAL_VARIABLES], 1, [enable global variables widgets])
-    AC_MSG_NOTICE([enabled global variables widgets])
-else
-    AC_MSG_NOTICE([disabled global variables widgets])
-fi
-
 dnl *******************************
 dnl checking for libraries we use
 dnl *******************************
@@ -430,7 +416,6 @@
     Enable workbench                : ${ENABLE_WORKBENCH}
     Enable memory view              : ${ENABLE_MEMORYVIEW}
     Enable variable walker          : ${ENABLE_VARIABLE_WALKER}
-    Enable gobal variables widget   : ${ENABLE_GLOBAL_VARIABLES}
     Enable symbols visibility ctrl  : ${ENABLE_GCC_SYMBOLS_VISIBILITY}
     Maintainer mode                 : ${USER_MAINTAINER_MODE}
     CFLAGS                          : ${CFLAGS}

Modified: trunk/src/persp/dbgperspective/nmv-local-vars-inspector2.cc
==============================================================================
--- trunk/src/persp/dbgperspective/nmv-local-vars-inspector2.cc	(original)
+++ trunk/src/persp/dbgperspective/nmv-local-vars-inspector2.cc	Thu Jan 10 03:00:52 2008
@@ -51,17 +51,11 @@
     IDebuggerSafePtr debugger ;
     IVarListWalkerSafePtr local_var_list_walker;
     IVarListWalkerSafePtr function_args_var_list_walker;
-#ifdef WITH_GLOBAL_VARIABLES
-    IVarListWalkerSafePtr global_variables_walker_list;
-#endif //WITH_GLOBAL_VARIABLES
 
     IWorkbench &workbench ;
     SafePtr<Gtk::TreeView> tree_view ;
     Glib::RefPtr<Gtk::TreeStore> tree_store ;
     Gtk::TreeModel::iterator cur_selected_row ;
-#ifdef WITH_GLOBAL_VARIABLES
-    SafePtr<Gtk::TreeRowReference> global_variables_row_ref ;
-#endif //WITH_GLOBAL_VARIABLES
     SafePtr<Gtk::TreeRowReference> local_variables_row_ref ;
     SafePtr<Gtk::TreeRowReference> function_arguments_row_ref ;
     std::map<UString, IDebugger::VariableSafePtr> local_vars_to_set ;
@@ -152,14 +146,6 @@
             (new Gtk::TreeRowReference (tree_store, tree_store->get_path (it)));
         THROW_IF_FAIL (function_arguments_row_ref) ;
 
-#ifdef WITH_GLOBAL_VARIABLES
-        it = tree_store->append () ;
-        THROW_IF_FAIL (it) ;
-        (*it)[vutil::get_variable_columns ().name] = _("Global Variables");
-        global_variables_row_ref.reset
-            (new Gtk::TreeRowReference (tree_store, tree_store->get_path (it)));
-        THROW_IF_FAIL (global_variables_row_ref) ;
-#endif //WITH_GLOBAL_VARIABLES
     }
 
     void get_function_arguments_row_iterator (Gtk::TreeModel::iterator &a_it)
@@ -174,14 +160,6 @@
         a_it = tree_store->get_iter (local_variables_row_ref->get_path ()) ;
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void get_global_variables_row_iterator (Gtk::TreeModel::iterator &a_it)
-    {
-        THROW_IF_FAIL (global_variables_row_ref) ;
-        a_it = tree_store->get_iter (global_variables_row_ref->get_path ()) ;
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     IVarListWalkerSafePtr get_local_vars_walker_list ()
     {
         if (!local_var_list_walker) {
@@ -206,20 +184,6 @@
         return function_args_var_list_walker ;
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    IVarListWalkerSafePtr get_global_variables_walker_list ()
-    {
-        if (!global_variables_walker_list) {
-            global_variables_walker_list = create_variable_walker_list () ;
-            THROW_IF_FAIL (global_variables_walker_list) ;
-            global_variables_walker_list->variable_visited_signal ().connect
-                (sigc::mem_fun
-                 (*this, &LocalVarsInspector2::Priv::on_global_variable_visited_signal)) ;
-        }
-        return global_variables_walker_list ;
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     IVarListWalkerSafePtr create_variable_walker_list ()
     {
         DynamicModule::Loader *loader =
@@ -247,10 +211,6 @@
             (sigc::mem_fun (*this, &Priv::on_local_variables_listed_signal)) ;
         debugger->frames_arguments_listed_signal ().connect
             (sigc::mem_fun (*this, &Priv::on_frames_params_listed_signal)) ;
-#ifdef WITH_GLOBAL_VARIABLES
-        debugger->global_variables_listed_signal ().connect
-            (sigc::mem_fun (*this, &Priv::on_global_variables_listed_signal)) ;
-#endif //WITH_GLOBAL_VARIABLES
     }
 
     void init_graphical_signals ()
@@ -290,20 +250,6 @@
         }
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void set_global_variables (const std::list<IDebugger::VariableSafePtr> &a_vars)
-    {
-        LOG_FUNCTION_SCOPE_NORMAL_DD ;
-
-        clear_global_variables () ;
-        std::list<IDebugger::VariableSafePtr>::const_iterator it ;
-        for (it = a_vars.begin () ; it != a_vars.end () ; ++it) {
-            THROW_IF_FAIL ((*it)->name () != "") ;
-            append_a_global_variable (*it) ;
-        }
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     void clear_local_variables ()
     {
         LOG_FUNCTION_SCOPE_NORMAL_DD ;
@@ -328,19 +274,6 @@
         }
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void clear_global_variables ()
-    {
-        THROW_IF_FAIL (tree_store) ;
-        Gtk::TreeModel::iterator row_it;
-        get_global_variables_row_iterator (row_it) ;
-        Gtk::TreeModel::Children rows = row_it->children ();
-        for (row_it = rows.begin (); row_it != rows.end (); ++row_it) {
-            tree_store->erase (*row_it) ;
-        }
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     void append_a_local_variable (const IDebugger::VariableSafePtr &a_var)
     {
         LOG_FUNCTION_SCOPE_NORMAL_DD ;
@@ -366,20 +299,6 @@
         tree_view->expand_row (tree_store->get_path (parent_row_it), false) ;
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void append_a_global_variable (const IDebugger::VariableSafePtr &a_var)
-    {
-        LOG_FUNCTION_SCOPE_NORMAL_DD ;
-
-        THROW_IF_FAIL (tree_view && tree_store) ;
-
-        Gtk::TreeModel::iterator parent_row_it ;
-        get_global_variables_row_iterator (parent_row_it) ;
-        vutil::append_a_variable (a_var, *tree_view, tree_store, parent_row_it) ;
-        tree_view->expand_row (tree_store->get_path (parent_row_it), false) ;
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     void update_a_local_variable (const IDebugger::VariableSafePtr &a_var)
     {
         LOG_FUNCTION_SCOPE_NORMAL_DD ;
@@ -404,19 +323,6 @@
                                   true, false) ;
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void update_a_global_variable (const IDebugger::VariableSafePtr &a_var)
-    {
-        LOG_FUNCTION_SCOPE_NORMAL_DD ;
-
-        THROW_IF_FAIL (tree_view) ;
-        Gtk::TreeModel::iterator parent_row_it ;
-        get_global_variables_row_iterator (parent_row_it) ;
-        vutil::update_a_variable (a_var, *tree_view, parent_row_it,
-                                  true, false) ;
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     //****************************
     //<debugger signal handlers>
     //****************************
@@ -452,9 +358,6 @@
                 LOG_DD ("init tree view") ;
                 re_init_tree_view () ;
                 debugger->list_local_variables () ;
-#ifdef WITH_GLOBAL_VARIABLES
-                debugger->list_global_variables () ;
-#endif //WITH_GLOBAL_VARIABLES
             } else {
                 IVarListWalkerSafePtr walker_list = get_local_vars_walker_list () ;
                 THROW_IF_FAIL (walker_list) ;
@@ -514,28 +417,6 @@
         NEMIVER_CATCH
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void on_global_variables_listed_signal
-                                (const list<IDebugger::VariableSafePtr> &a_vars,
-                                 const UString &a_cookie)
-    {
-        LOG_FUNCTION_SCOPE_NORMAL_DD ;
-
-        if (a_cookie == "") {}
-
-        NEMIVER_TRY
-
-        IVarListWalkerSafePtr walker_list = get_global_variables_walker_list () ;
-        THROW_IF_FAIL (walker_list) ;
-
-        walker_list->remove_variables () ;
-        walker_list->append_variables (a_vars) ;
-        walker_list->do_walk_variables () ;
-
-        NEMIVER_CATCH
-    }
-#endif //WITH_GLOBAL_VARIABLES
-
     //****************************
     //</debugger signal handlers>
     //****************************
@@ -576,24 +457,6 @@
         NEMIVER_CATCH
     }
 
-#ifdef WITH_GLOBAL_VARIABLES
-    void on_global_variable_visited_signal (const IVarWalkerSafePtr &a_walker)
-    {
-        LOG_FUNCTION_SCOPE_NORMAL_DD ;
-
-        NEMIVER_TRY
-
-        THROW_IF_FAIL (a_walker->get_variable ()) ;
-
-        if (is_new_frame) {
-            append_a_global_variable (a_walker->get_variable ()) ;
-        } else {
-            update_a_global_variable (a_walker->get_variable ()) ;
-        }
-
-        NEMIVER_CATCH
-    }
-#endif //WITH_GLOBAL_VARIABLES
     void on_tree_view_selection_changed_signal ()
     {
     }



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