1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_SC_SOURCE_UI_INC_TABOPDLG_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_TABOPDLG_HXX
23 #include <vcl/fixed.hxx>
24 #include <vcl/group.hxx>
26 #include "address.hxx"
27 #include "anyrefdg.hxx"
31 TABOPERR_NOFORMULA
= 1,
33 TABOPERR_WRONGFORMULA
,
35 TABOPERR_NOCOLFORMULA
,
40 class ScTabOpDlg
: public ScAnyRefDlg
43 ScTabOpDlg( SfxBindings
* pB
, SfxChildWindow
* pCW
, vcl::Window
* pParent
,
44 ScDocument
* pDocument
,
45 const ScRefAddress
& rCursorPos
);
46 virtual ~ScTabOpDlg();
47 virtual void dispose() override
;
49 virtual void SetReference( const ScRange
& rRef
, ScDocument
* pDoc
) override
;
50 virtual bool IsRefInputMode() const override
{ return true; }
51 virtual void SetActive() override
;
53 virtual bool Close() override
;
56 VclPtr
<FixedText
> m_pFtFormulaRange
;
57 VclPtr
<formula::RefEdit
> m_pEdFormulaRange
;
58 VclPtr
<formula::RefButton
> m_pRBFormulaRange
;
60 VclPtr
<FixedText
> m_pFtRowCell
;
61 VclPtr
<formula::RefEdit
> m_pEdRowCell
;
62 VclPtr
<formula::RefButton
> m_pRBRowCell
;
64 VclPtr
<FixedText
> m_pFtColCell
;
65 VclPtr
<formula::RefEdit
> m_pEdColCell
;
66 VclPtr
<formula::RefButton
> m_pRBColCell
;
68 VclPtr
<OKButton
> m_pBtnOk
;
69 VclPtr
<CancelButton
> m_pBtnCancel
;
71 ScRefAddress theFormulaCell
;
72 ScRefAddress theFormulaEnd
;
73 ScRefAddress theRowCell
;
74 ScRefAddress theColCell
;
78 VclPtr
<formula::RefEdit
> pEdActive
;
80 const OUString errMsgNoFormula
;
81 const OUString errMsgNoColRow
;
82 const OUString errMsgWrongFormula
;
83 const OUString errMsgWrongRowCol
;
84 const OUString errMsgNoColFormula
;
85 const OUString errMsgNoRowFormula
;
88 void RaiseError( ScTabOpErr eError
);
90 DECL_LINK_TYPED( BtnHdl
, Button
*, void );
91 DECL_LINK_TYPED( GetFocusHdl
, Control
&, void );
92 DECL_LINK_TYPED( LoseFocusHdl
, Control
&, void );
95 #endif // INCLUDED_SC_SOURCE_UI_INC_TABOPDLG_HXX
97 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */