Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
8fb84ee6
Kaydet (Commit)
8fb84ee6
authored
Eki 13, 2012
tarafından
Markus Mohrhard
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
sal_Bool to bool in anyrefdg.[ch]xx
Change-Id: I4efa09c0185e7825d5b705ca0171f52b8aae17df
üst
d342c9be
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
35 deletions
+35
-35
anyrefdg.hxx
sc/source/ui/inc/anyrefdg.hxx
+12
-12
anyrefdg.cxx
sc/source/ui/miscdlgs/anyrefdg.cxx
+23
-23
No files found.
sc/source/ui/inc/anyrefdg.hxx
Dosyayı görüntüle @
8fb84ee6
...
@@ -62,7 +62,7 @@ class ScFormulaReferenceHelper
...
@@ -62,7 +62,7 @@ class ScFormulaReferenceHelper
SfxBindings
*
m_pBindings
;
SfxBindings
*
m_pBindings
;
::
std
::
auto_ptr
<
Accelerator
>
::
std
::
auto_ptr
<
Accelerator
>
pAccel
;
// for Enter/Escape
pAccel
;
// for Enter/Escape
sal_B
ool
*
pHiddenMarks
;
// Mark field for hidden Controls
b
ool
*
pHiddenMarks
;
// Mark field for hidden Controls
SCTAB
nRefTab
;
// used for ShowReference
SCTAB
nRefTab
;
// used for ShowReference
String
sOldDialogText
;
// Original title of the dialog window
String
sOldDialogText
;
// Original title of the dialog window
...
@@ -72,9 +72,9 @@ class ScFormulaReferenceHelper
...
@@ -72,9 +72,9 @@ class ScFormulaReferenceHelper
Point
aOldButtonPos
;
// Original position of the button
Point
aOldButtonPos
;
// Original position of the button
Window
*
mpOldEditParent
;
// Original parent of the edit field and the button
Window
*
mpOldEditParent
;
// Original parent of the edit field and the button
sal_B
ool
bEnableColorRef
;
b
ool
bEnableColorRef
;
sal_B
ool
bHighLightRef
;
b
ool
bHighLightRef
;
sal_B
ool
bAccInserted
;
b
ool
bAccInserted
;
DECL_LINK
(
AccelSelectHdl
,
Accelerator
*
);
DECL_LINK
(
AccelSelectHdl
,
Accelerator
*
);
...
@@ -89,25 +89,25 @@ public:
...
@@ -89,25 +89,25 @@ public:
void
ShowReference
(
const
XubString
&
rStr
);
void
ShowReference
(
const
XubString
&
rStr
);
void
ReleaseFocus
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
void
ReleaseFocus
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
void
HideReference
(
sal_Bool
bDoneRefMode
=
sal_T
rue
);
void
HideReference
(
bool
bDoneRefMode
=
t
rue
);
void
RefInputStart
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
void
RefInputStart
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
void
RefInputDone
(
sal_B
ool
bForced
=
false
);
void
RefInputDone
(
b
ool
bForced
=
false
);
void
ToggleCollapsed
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
void
ToggleCollapsed
(
formula
::
RefEdit
*
pEdit
,
formula
::
RefButton
*
pButton
=
NULL
);
inline
void
SetWindow
(
Window
*
_pWindow
)
{
m_pWindow
=
_pWindow
;
}
inline
void
SetWindow
(
Window
*
_pWindow
)
{
m_pWindow
=
_pWindow
;
}
sal_B
ool
DoClose
(
sal_uInt16
nId
);
b
ool
DoClose
(
sal_uInt16
nId
);
void
SetDispatcherLock
(
sal_B
ool
bLock
);
void
SetDispatcherLock
(
b
ool
bLock
);
void
EnableSpreadsheets
(
sal_Bool
bFlag
=
sal_True
,
sal_Bool
bChildren
=
sal_T
rue
);
void
EnableSpreadsheets
(
bool
bFlag
=
true
,
bool
bChildren
=
t
rue
);
void
ViewShellChanged
(
ScTabViewShell
*
pScViewShell
);
void
ViewShellChanged
(
ScTabViewShell
*
pScViewShell
);
static
void
enableInput
(
sal_B
ool
_bInput
);
static
void
enableInput
(
b
ool
_bInput
);
protected
:
protected
:
Window
*
GetWindow
(){
return
m_pWindow
;
}
Window
*
GetWindow
(){
return
m_pWindow
;
}
public
:
public
:
bool
CanInputStart
(
const
formula
::
RefEdit
*
pEdit
){
return
!!
pEdit
;
}
bool
CanInputStart
(
const
formula
::
RefEdit
*
pEdit
){
return
!!
pEdit
;
}
bool
CanInputDone
(
sal_B
ool
bForced
){
return
pRefEdit
&&
(
bForced
||
!
pRefBtn
);
}
bool
CanInputDone
(
b
ool
bForced
){
return
pRefEdit
&&
(
bForced
||
!
pRefBtn
);
}
};
};
//============================================================================
//============================================================================
...
@@ -139,7 +139,7 @@ private:
...
@@ -139,7 +139,7 @@ private:
protected
:
protected
:
virtual
sal_Bool
DoClose
(
sal_uInt16
nId
);
virtual
sal_Bool
DoClose
(
sal_uInt16
nId
);
void
SetDispatcherLock
(
sal_B
ool
bLock
);
void
SetDispatcherLock
(
b
ool
bLock
);
//Overwrite TWindow will implemented by ScRefHdlrImplBase
//Overwrite TWindow will implemented by ScRefHdlrImplBase
//virtual long PreNotify( NotifyEvent& rNEvt );
//virtual long PreNotify( NotifyEvent& rNEvt );
...
...
sc/source/ui/miscdlgs/anyrefdg.cxx
Dosyayı görüntüle @
8fb84ee6
...
@@ -76,14 +76,14 @@ ScFormulaReferenceHelper::~ScFormulaReferenceHelper()
...
@@ -76,14 +76,14 @@ ScFormulaReferenceHelper::~ScFormulaReferenceHelper()
// common cleanup for ScAnyRefDlg and ScFormulaDlg is done here
// common cleanup for ScAnyRefDlg and ScFormulaDlg is done here
HideReference
();
HideReference
();
enableInput
(
sal_T
rue
);
enableInput
(
t
rue
);
ScInputHandler
*
pInputHdl
=
SC_MOD
()
->
GetInputHdl
();
ScInputHandler
*
pInputHdl
=
SC_MOD
()
->
GetInputHdl
();
if
(
pInputHdl
)
if
(
pInputHdl
)
pInputHdl
->
ResetDelayTimer
();
// stop the timer for disabling the input line
pInputHdl
->
ResetDelayTimer
();
// stop the timer for disabling the input line
}
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
void
ScFormulaReferenceHelper
::
enableInput
(
sal_B
ool
bEnable
)
void
ScFormulaReferenceHelper
::
enableInput
(
b
ool
bEnable
)
{
{
TypeId
aType
(
TYPE
(
ScDocShell
));
TypeId
aType
(
TYPE
(
ScDocShell
));
ScDocShell
*
pDocShell
=
(
ScDocShell
*
)
SfxObjectShell
::
GetFirst
(
&
aType
);
ScDocShell
*
pDocShell
=
(
ScDocShell
*
)
SfxObjectShell
::
GetFirst
(
&
aType
);
...
@@ -105,8 +105,8 @@ void ScFormulaReferenceHelper::enableInput( sal_Bool bEnable )
...
@@ -105,8 +105,8 @@ void ScFormulaReferenceHelper::enableInput( sal_Bool bEnable )
Window
*
pParent
=
pWin
->
GetParent
();
Window
*
pParent
=
pWin
->
GetParent
();
if
(
pParent
)
if
(
pParent
)
{
{
pParent
->
EnableInput
(
bEnable
,
sal_T
rue
/* sal_False */
);
pParent
->
EnableInput
(
bEnable
,
t
rue
/* sal_False */
);
if
(
sal_T
rue
/*bChildren*/
)
if
(
t
rue
/*bChildren*/
)
pViewSh
->
EnableRefInput
(
bEnable
);
pViewSh
->
EnableRefInput
(
bEnable
);
}
}
}
}
...
@@ -123,7 +123,7 @@ void ScFormulaReferenceHelper::ShowSimpleReference( const XubString& rStr )
...
@@ -123,7 +123,7 @@ void ScFormulaReferenceHelper::ShowSimpleReference( const XubString& rStr )
{
{
if
(
bEnableColorRef
)
if
(
bEnableColorRef
)
{
{
bHighLightRef
=
sal_T
rue
;
bHighLightRef
=
t
rue
;
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
if
(
pViewData
)
if
(
pViewData
)
{
{
...
@@ -183,7 +183,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
...
@@ -183,7 +183,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
{
{
if
(
/*!pRefEdit &&*/
bEnableColorRef
)
if
(
/*!pRefEdit &&*/
bEnableColorRef
)
{
{
bHighLightRef
=
sal_T
rue
;
bHighLightRef
=
t
rue
;
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
if
(
pViewData
&&
pRefComp
.
get
()
)
if
(
pViewData
&&
pRefComp
.
get
()
)
{
{
...
@@ -208,7 +208,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
...
@@ -208,7 +208,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
while
(
pToken
!=
NULL
)
while
(
pToken
!=
NULL
)
{
{
sal_B
ool
bDoubleRef
=
(
pToken
->
GetType
()
==
formula
::
svDoubleRef
);
b
ool
bDoubleRef
=
(
pToken
->
GetType
()
==
formula
::
svDoubleRef
);
if
(
pToken
->
GetType
()
==
formula
::
svSingleRef
||
bDoubleRef
)
if
(
pToken
->
GetType
()
==
formula
::
svSingleRef
||
bDoubleRef
)
...
@@ -240,7 +240,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
...
@@ -240,7 +240,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference( const XubString& rStr )
}
}
}
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
void
ScFormulaReferenceHelper
::
HideReference
(
sal_B
ool
bDoneRefMode
)
void
ScFormulaReferenceHelper
::
HideReference
(
b
ool
bDoneRefMode
)
{
{
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
ScViewData
*
pViewData
=
ScDocShell
::
GetViewData
();
...
@@ -310,7 +310,7 @@ void ScFormulaReferenceHelper::ReleaseFocus( formula::RefEdit* pEdit, formula::R
...
@@ -310,7 +310,7 @@ void ScFormulaReferenceHelper::ReleaseFocus( formula::RefEdit* pEdit, formula::R
pViewShell
->
MoveCursorAbs
(
pRange
->
aStart
.
Col
(),
pViewShell
->
MoveCursorAbs
(
pRange
->
aStart
.
Col
(),
pRange
->
aStart
.
Row
(),
SC_FOLLOW_JUMP
,
false
,
false
);
pRange
->
aStart
.
Row
(),
SC_FOLLOW_JUMP
,
false
,
false
);
pViewShell
->
MoveCursorAbs
(
pRange
->
aEnd
.
Col
(),
pViewShell
->
MoveCursorAbs
(
pRange
->
aEnd
.
Col
(),
pRange
->
aEnd
.
Row
(),
SC_FOLLOW_JUMP
,
sal_T
rue
,
false
);
pRange
->
aEnd
.
Row
(),
SC_FOLLOW_JUMP
,
t
rue
,
false
);
m_pDlg
->
SetReference
(
*
pRange
,
pDoc
);
m_pDlg
->
SetReference
(
*
pRange
,
pDoc
);
}
}
}
}
...
@@ -333,7 +333,7 @@ void ScFormulaReferenceHelper::Init()
...
@@ -333,7 +333,7 @@ void ScFormulaReferenceHelper::Init()
pRefCell
.
reset
(
new
ScFormulaCell
(
pDoc
,
aCursorPos
,
rStrExp
)
);
pRefCell
.
reset
(
new
ScFormulaCell
(
pDoc
,
aCursorPos
,
rStrExp
)
);
pRefComp
.
reset
(
new
ScCompiler
(
pDoc
,
aCursorPos
)
);
pRefComp
.
reset
(
new
ScCompiler
(
pDoc
,
aCursorPos
)
);
pRefComp
->
SetGrammar
(
pDoc
->
GetGrammar
()
);
pRefComp
->
SetGrammar
(
pDoc
->
GetGrammar
()
);
pRefComp
->
SetCompileForFAP
(
sal_T
rue
);
pRefComp
->
SetCompileForFAP
(
t
rue
);
nRefTab
=
nTab
;
nRefTab
=
nTab
;
}
}
...
@@ -350,13 +350,13 @@ IMPL_LINK( ScFormulaReferenceHelper, AccelSelectHdl, Accelerator *, pSelAccel )
...
@@ -350,13 +350,13 @@ IMPL_LINK( ScFormulaReferenceHelper, AccelSelectHdl, Accelerator *, pSelAccel )
case
KEY_ESCAPE
:
case
KEY_ESCAPE
:
if
(
pRefEdit
)
if
(
pRefEdit
)
pRefEdit
->
GrabFocus
();
pRefEdit
->
GrabFocus
();
m_pDlg
->
RefInputDone
(
sal_T
rue
);
m_pDlg
->
RefInputDone
(
t
rue
);
break
;
break
;
}
}
return
sal_T
rue
;
return
t
rue
;
}
}
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
void
ScFormulaReferenceHelper
::
RefInputDone
(
sal_B
ool
bForced
)
void
ScFormulaReferenceHelper
::
RefInputDone
(
b
ool
bForced
)
{
{
if
(
CanInputDone
(
bForced
)
)
if
(
CanInputDone
(
bForced
)
)
{
{
...
@@ -428,7 +428,7 @@ void ScFormulaReferenceHelper::RefInputStart( formula::RefEdit* pEdit, formula::
...
@@ -428,7 +428,7 @@ void ScFormulaReferenceHelper::RefInputStart( formula::RefEdit* pEdit, formula::
// Alle Elemente ausser EditCell und Button verstecken
// Alle Elemente ausser EditCell und Button verstecken
sal_uInt16
nChildren
=
m_pWindow
->
GetChildCount
();
sal_uInt16
nChildren
=
m_pWindow
->
GetChildCount
();
pHiddenMarks
=
new
sal_B
ool
[
nChildren
];
pHiddenMarks
=
new
b
ool
[
nChildren
];
for
(
sal_uInt16
i
=
0
;
i
<
nChildren
;
i
++
)
for
(
sal_uInt16
i
=
0
;
i
<
nChildren
;
i
++
)
{
{
pHiddenMarks
[
i
]
=
false
;
pHiddenMarks
[
i
]
=
false
;
...
@@ -442,7 +442,7 @@ void ScFormulaReferenceHelper::RefInputStart( formula::RefEdit* pEdit, formula::
...
@@ -442,7 +442,7 @@ void ScFormulaReferenceHelper::RefInputStart( formula::RefEdit* pEdit, formula::
;
// do nothing
;
// do nothing
else
if
(
pWin
->
IsVisible
())
else
if
(
pWin
->
IsVisible
())
{
{
pHiddenMarks
[
i
]
=
sal_T
rue
;
pHiddenMarks
[
i
]
=
t
rue
;
pWin
->
Hide
();
pWin
->
Hide
();
}
}
}
}
...
@@ -498,11 +498,11 @@ void ScFormulaReferenceHelper::ToggleCollapsed( formula::RefEdit* pEdit, formula
...
@@ -498,11 +498,11 @@ void ScFormulaReferenceHelper::ToggleCollapsed( formula::RefEdit* pEdit, formula
if
(
pRefEdit
==
pEdit
)
// is this the active ref edit field?
if
(
pRefEdit
==
pEdit
)
// is this the active ref edit field?
{
{
pRefEdit
->
GrabFocus
();
// before RefInputDone()
pRefEdit
->
GrabFocus
();
// before RefInputDone()
m_pDlg
->
RefInputDone
(
sal_T
rue
);
// finish ref input
m_pDlg
->
RefInputDone
(
t
rue
);
// finish ref input
}
}
else
else
{
{
m_pDlg
->
RefInputDone
(
sal_T
rue
);
// another active ref edit?
m_pDlg
->
RefInputDone
(
t
rue
);
// another active ref edit?
m_pDlg
->
RefInputStart
(
pEdit
,
pButton
);
// start ref input
m_pDlg
->
RefInputStart
(
pEdit
,
pButton
);
// start ref input
// pRefEdit might differ from pEdit after RefInputStart() (i.e. ScFormulaDlg)
// pRefEdit might differ from pEdit after RefInputStart() (i.e. ScFormulaDlg)
if
(
pRefEdit
)
if
(
pRefEdit
)
...
@@ -511,7 +511,7 @@ void ScFormulaReferenceHelper::ToggleCollapsed( formula::RefEdit* pEdit, formula
...
@@ -511,7 +511,7 @@ void ScFormulaReferenceHelper::ToggleCollapsed( formula::RefEdit* pEdit, formula
}
}
}
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
sal_B
ool
ScFormulaReferenceHelper
::
DoClose
(
sal_uInt16
nId
)
b
ool
ScFormulaReferenceHelper
::
DoClose
(
sal_uInt16
nId
)
{
{
SfxApplication
*
pSfxApp
=
SFX_APP
();
SfxApplication
*
pSfxApp
=
SFX_APP
();
...
@@ -545,11 +545,11 @@ sal_Bool ScFormulaReferenceHelper::DoClose( sal_uInt16 nId )
...
@@ -545,11 +545,11 @@ sal_Bool ScFormulaReferenceHelper::DoClose( sal_uInt16 nId )
ScTabViewShell
*
pScViewShell
=
ScTabViewShell
::
GetActiveViewShell
();
ScTabViewShell
*
pScViewShell
=
ScTabViewShell
::
GetActiveViewShell
();
if
(
pScViewShell
)
if
(
pScViewShell
)
pScViewShell
->
UpdateInputHandler
(
sal_T
rue
);
pScViewShell
->
UpdateInputHandler
(
t
rue
);
return
sal_T
rue
;
return
t
rue
;
}
}
void
ScFormulaReferenceHelper
::
SetDispatcherLock
(
sal_B
ool
bLock
)
void
ScFormulaReferenceHelper
::
SetDispatcherLock
(
b
ool
bLock
)
{
{
// lock / unlock only the dispatchers of Calc documents
// lock / unlock only the dispatchers of Calc documents
...
@@ -580,7 +580,7 @@ void ScFormulaReferenceHelper::ViewShellChanged(ScTabViewShell* /* pScViewShell
...
@@ -580,7 +580,7 @@ void ScFormulaReferenceHelper::ViewShellChanged(ScTabViewShell* /* pScViewShell
EnableSpreadsheets
();
EnableSpreadsheets
();
}
}
void
ScFormulaReferenceHelper
::
EnableSpreadsheets
(
sal_Bool
bFlag
,
sal_B
ool
bChildren
)
void
ScFormulaReferenceHelper
::
EnableSpreadsheets
(
bool
bFlag
,
b
ool
bChildren
)
{
{
TypeId
aType
(
TYPE
(
ScDocShell
));
TypeId
aType
(
TYPE
(
ScDocShell
));
ScDocShell
*
pDocShell
=
(
ScDocShell
*
)
SfxObjectShell
::
GetFirst
(
&
aType
);
ScDocShell
*
pDocShell
=
(
ScDocShell
*
)
SfxObjectShell
::
GetFirst
(
&
aType
);
...
@@ -824,7 +824,7 @@ sal_Bool ScRefHandler::DoClose( sal_uInt16 nId )
...
@@ -824,7 +824,7 @@ sal_Bool ScRefHandler::DoClose( sal_uInt16 nId )
return
sal_True
;
return
sal_True
;
}
}
void
ScRefHandler
::
SetDispatcherLock
(
sal_B
ool
bLock
)
void
ScRefHandler
::
SetDispatcherLock
(
b
ool
bLock
)
{
{
m_aHelper
.
SetDispatcherLock
(
bLock
);
m_aHelper
.
SetDispatcherLock
(
bLock
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment