summaryrefslogtreecommitdiffstats
path: root/sc
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2011-09-24 01:43:07 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2011-09-24 03:52:33 +0200
commit176b9ee183fdaa5837d0d436720ecb199e80f480 (patch)
treed6754e5b3c6370bc23353aad2d0794aa467e125b /sc
parentManage Names: refactoring in namedlg.cxx (diff)
downloadcore-176b9ee183fdaa5837d0d436720ecb199e80f480.tar.gz
core-176b9ee183fdaa5837d0d436720ecb199e80f480.zip
Manage Names: add comments and remove dead code
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/inc/namedlg.hxx6
-rw-r--r--sc/source/ui/namedlg/namedlg.cxx13
2 files changed, 6 insertions, 13 deletions
diff --git a/sc/source/ui/inc/namedlg.hxx b/sc/source/ui/inc/namedlg.hxx
index 713a129f4f4f..8a556234bebf 100644
--- a/sc/source/ui/inc/namedlg.hxx
+++ b/sc/source/ui/inc/namedlg.hxx
@@ -57,6 +57,10 @@ struct ScRangeNameLine
rtl::OUString aScope;
};
+//Implements the table for the manage names dialog
+//TODO: cache the lines for performance improvements
+//otherwise handling of a large set of range names might get extremely slow
+//Need some sort of a filter to handle several range names
class ScRangeManagerTable : public SvTabListBox
{
private:
@@ -127,6 +131,7 @@ public:
//==================================================================
+//logic behind the manage names dialog
class ScNameDlg : public ScAnyRefDlg
{
private:
@@ -192,7 +197,6 @@ private:
DECL_LINK( ModifyBtnHdl, void * );
DECL_LINK( RemoveBtnHdl, void * );
DECL_LINK( EdModifyHdl, void * );
- DECL_LINK( NameSelectHdl, void * );
DECL_LINK( AssignGetFocusHdl, void * );
DECL_LINK( SelectionChangedHdl_Impl, void* );
DECL_LINK( BackBtnHdl, void * );
diff --git a/sc/source/ui/namedlg/namedlg.cxx b/sc/source/ui/namedlg/namedlg.cxx
index e8bd6f4b74ed..494a6d011ec8 100644
--- a/sc/source/ui/namedlg/namedlg.cxx
+++ b/sc/source/ui/namedlg/namedlg.cxx
@@ -384,6 +384,7 @@ void ScNameDlg::UpdateChecks(ScRangeData* pData)
maBtnRowHeader.Check( pData->HasType( RT_ROWHEADER ) );
}
+//updates the table and the buttons
void ScNameDlg::UpdateNames()
{
mpRangeManagerTable->UpdateEntries();
@@ -505,16 +506,10 @@ void ScNameDlg::RemovePushed()
maUndoStack.push( new ScNameManagerUndoDelete( pRangeName, new ScRangeData(*pData) ));
pRangeName->erase(*pData);
UpdateNames();
- maBtnAdd.Disable();
}
}
}
-void ScNameDlg::NameSelected()
-{
-
-}
-
void ScNameDlg::NameModified()
{
rtl::OUString aName = maEdName.GetText();
@@ -669,12 +664,6 @@ IMPL_LINK( ScNameDlg, RemoveBtnHdl, void *, EMPTYARG )
return 0;
}
-IMPL_LINK( ScNameDlg, NameSelectHdl, void *, EMPTYARG )
-{
- NameSelected();
- return 0;
-}
-
IMPL_LINK( ScNameDlg, EdModifyHdl, void *, EMPTYARG )
{
NameModified();