summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-05-25 13:42:16 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-05-25 14:24:20 +0100
commit07f1a395098a7a3ac75eb5f05c35aa3982e33e67 (patch)
treede5521de6b2bc6c9a09ddfab61942a8e27214ebb /include
parentd9ac7def8ba320853e8865535a7a14f9af77521e (diff)
(nearly) nothing uses GetUniqueId anymore, so remove it.
The odd one out is the usage in Formula, which attempts to restore focus to a particular window identified by an unique id. In this case restore focus by keeping a VclPtr to the desired window. Change-Id: I1dc335325c109d75745c6bba2e12662e6ae50638
Diffstat (limited to 'include')
-rw-r--r--include/formula/formdata.hxx8
-rw-r--r--include/formula/formula.hxx2
-rw-r--r--include/sfx2/basedlgs.hxx10
-rw-r--r--include/tools/rc.h5
-rw-r--r--include/vcl/tabctrl.hxx1
-rw-r--r--include/vcl/window.hxx3
6 files changed, 6 insertions, 23 deletions
diff --git a/include/formula/formdata.hxx b/include/formula/formdata.hxx
index 5f4877e76d1c..2e16b806bf19 100644
--- a/include/formula/formdata.hxx
+++ b/include/formula/formdata.hxx
@@ -23,7 +23,7 @@
#include <formula/formuladllapi.h>
#include <rtl/ustring.hxx>
#include <tools/gen.hxx>
-
+#include <vcl/window.hxx>
namespace formula
{
@@ -43,7 +43,7 @@ public:
inline sal_uInt16 GetEdFocus() const { return nEdFocus; }
inline const OUString& GetUndoStr() const { return aUndoStr; }
inline bool GetMatrixFlag()const{ return bMatrix;}
- const OString& GetUniqueId()const { return aUniqueId;}
+ const VclPtr<vcl::Window>& GetFocusWindow()const { return xFocusWin; }
inline const Selection& GetSelection()const { return aSelection;}
inline void SetMode( sal_uInt16 nNew ) { nMode = nNew; }
@@ -52,7 +52,7 @@ public:
inline void SetEdFocus( sal_uInt16 nNew ) { nEdFocus = nNew; }
inline void SetUndoStr( const OUString& rNew ) { aUndoStr = rNew; }
inline void SetMatrixFlag(bool bNew) { bMatrix=bNew;}
- inline void SetUniqueId(const OString& nNew) { aUniqueId=nNew;}
+ inline void SetFocusWindow(const VclPtr<vcl::Window>& rWin) { xFocusWin=rWin;}
inline void SetSelection(const Selection& aSel) { aSelection=aSel;}
protected:
void Reset();
@@ -69,7 +69,7 @@ private:
sal_uInt16 nEdFocus;
OUString aUndoStr;
bool bMatrix;
- OString aUniqueId;
+ VclPtr<vcl::Window> xFocusWin;
Selection aSelection;
};
diff --git a/include/formula/formula.hxx b/include/formula/formula.hxx
index 2456cb00154e..5cf4c9583b3b 100644
--- a/include/formula/formula.hxx
+++ b/include/formula/formula.hxx
@@ -64,7 +64,6 @@ protected:
::std::pair<RefButton*,RefEdit*> RefInputStartBefore( RefEdit* pEdit, RefButton* pButton = nullptr );
void RefInputStartAfter( RefEdit* pEdit, RefButton* pButton = nullptr );
void RefInputDoneAfter();
- void SetFocusWin(vcl::Window *pWin,const OString& nUniqueId);
void SetMeText(const OUString& _sText);
void Update();
@@ -104,7 +103,6 @@ protected:
::std::pair<RefButton*,RefEdit*> RefInputStartBefore( RefEdit* pEdit, RefButton* pButton = nullptr );
void RefInputStartAfter( RefEdit* pEdit, RefButton* pButton = nullptr );
void RefInputDoneAfter( bool bForced = false );
- void SetFocusWin(vcl::Window *pWin,const OString& nUniqueId);
void SetMeText(const OUString& _sText);
FormulaDlgMode SetMeText(const OUString& _sText, sal_Int32 PrivStart, sal_Int32 PrivEnd, bool bMatrix, bool _bSelect, bool _bUpdate);
diff --git a/include/sfx2/basedlgs.hxx b/include/sfx2/basedlgs.hxx
index 911e2dabf33e..55550b74ac5e 100644
--- a/include/sfx2/basedlgs.hxx
+++ b/include/sfx2/basedlgs.hxx
@@ -40,16 +40,6 @@ class HelpButton;
class Button;
class FixedLine;
-//There is a hack which hides the HelpId for a Dialog in SfxModelessDialog
-//and SfxDockingWindow, where it is changed into a UniqueId and cleared
-//This reverses the clear of the HelpId
-
-inline void reverseUniqueHelpIdHack(vcl::Window &rWindow)
-{
- if (rWindow.GetHelpId().isEmpty())
- rWindow.SetHelpId(rWindow.GetUniqueId());
-}
-
// class SfxModalDialog --------------------------------------------------
class SFX2_DLLPUBLIC SfxModalDialog: public ModalDialog
diff --git a/include/tools/rc.h b/include/tools/rc.h
index 714ea98b5236..b84e6e27f595 100644
--- a/include/tools/rc.h
+++ b/include/tools/rc.h
@@ -48,9 +48,8 @@ namespace o3tl {
#define WINDOW_HELPTEXT 0x0100
#define WINDOW_QUICKTEXT 0x0200
#define WINDOW_EXTRALONG 0x0800
-#define WINDOW_UNIQUEID 0x1000
-#define WINDOW_BORDER_STYLE 0x2000
-#define WINDOW_HELPID 0x4000
+#define WINDOW_BORDER_STYLE 0x1000
+#define WINDOW_HELPID 0x2000
// For "WorkWindow" resources:
diff --git a/include/vcl/tabctrl.hxx b/include/vcl/tabctrl.hxx
index 8997a1ad99ae..4b34ae0f40e7 100644
--- a/include/vcl/tabctrl.hxx
+++ b/include/vcl/tabctrl.hxx
@@ -55,7 +55,6 @@ private:
sal_uInt16 mnCurPageId;
bool mbFormat;
bool mbRestoreHelpId;
- bool mbRestoreUnqId;
bool mbSmallInvalidate;
bool mbLayoutDirty;
Link<TabControl*,void> maActivateHdl;
diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx
index 9f6f7efb2115..a2f3276ceefc 100644
--- a/include/vcl/window.hxx
+++ b/include/vcl/window.hxx
@@ -1179,9 +1179,6 @@ public:
void SetHelpId( const OString& );
const OString& GetHelpId() const;
- void SetUniqueId( const OString& );
- const OString& GetUniqueId() const;
-
vcl::Window* FindWindow( const Point& rPos ) const;
sal_uInt16 GetChildCount() const;