29#include <com/sun/star/sdbc/XConnection.hpp>
38#define BROW_FIELD_ROW 0
39#define BROW_COLUMNALIAS_ROW 1
40#define BROW_TABLE_ROW 2
41#define BROW_ORDER_ROW 3
43#define BROW_FUNCTION_ROW 5
44#define BROW_CRIT1_ROW 6
45#define BROW_CRIT2_ROW 7
46#define BROW_CRIT3_ROW 8
47#define BROW_CRIT4_ROW 9
48#define BROW_CRIT5_ROW 10
49#define BROW_CRIT6_ROW 11
50#define BROW_ROW_CNT 12
52 class OQueryDesignView;
84 virtual void dispose()
override;
99 const OUString& rValue,
100 const sal_uInt16 nLevel,
101 bool _bAddOrOnOneLine );
115 void SetCellContents(sal_Int32 nCellIndex, sal_uInt16 nColId,
const OUString& strNewText);
137 void ColumnMoved( sal_uInt16 nColId,
bool _bCreateUndo);
157 virtual OUString
GetCellText(sal_Int32 _nRow, sal_uInt16 _nColId)
const override;
182 virtual css::uno::Reference< css::accessibility::XAccessible >
CreateAccessibleCell( sal_Int32 nRow, sal_uInt16 nColumnId )
override;
185 virtual bool SeekRow( sal_Int32 nRow )
override;
189 sal_uInt16 nColumnId )
const override;
198 virtual ::svt::CellController*
GetController(sal_Int32 nRow, sal_uInt16 nCol)
override;
202 virtual void Init()
override;
205 virtual sal_uInt32
GetTotalCellWidth(sal_Int32 nRow, sal_uInt16 nColId)
override;
226 void appendUndoAction(
const OUString& _rOldValue,std::u16string_view _rNewValue,sal_Int32 _nRow,
bool& _bListAction);
227 void appendUndoAction(
const OUString& _rOldValue,std::u16string_view _rNewValue,sal_Int32 _nRow);
271 const css::uno::Reference< css::sdbc::XConnection >& _rxConnection,
275 std::u16string_view _sTableRange,
276 const css::uno::Reference< css::sdbc::XDatabaseMetaData >& _xMetaData,
288 void notifyTableFieldChanged(
const OUString& _sOldAlias,std::u16string_view _sAlias,
bool& _bListAction,sal_uInt16 _nColumnId);
298 void notifyFunctionFieldChanged(
const OUString& _sOldFunctionName,std::u16string_view _sFunctionName,
bool& _bListAction,sal_uInt16 _nColumnId);
317 using ::svt::EditBrowseBox::AcceptDrop;
318 using ::svt::EditBrowseBox::ExecuteDrop;
319 using ::svt::EditBrowseBox::MouseButtonDown;
320 using ::svt::EditBrowseBox::MouseButtonUp;
AccessibleBrowseBoxObjType
bool saveField(OUString &_sFieldName, OTableFieldDescRef const &_pEntry, bool &_bListAction)
save the field change in save modified
sal_Int32 GetBrowseRow(sal_Int32 nRowId) const
tools::Rectangle GetInvalidRect(sal_uInt16 nColId)
void SetColWidth(sal_uInt16 nColId, tools::Long lNewWidth)
virtual VclPtr< BrowserHeader > imp_CreateHeaderBar(BrowseBox *pParent) override
OTableFieldDescRef InsertField(const OJoinExchangeData &jxdSource)
sal_Int32 GetNoneVisibleRows() const
virtual ::svt::CellController * GetController(sal_Int32 nRow, sal_uInt16 nCol) override
virtual void CellModified() override
void SetCellContents(sal_Int32 nCellIndex, sal_uInt16 nColId, const OUString &strNewText)
void RemoveColumn(sal_uInt16 _nColumnId)
OTableFieldDescRef FindFirstFreeCol(sal_uInt16 &_rColumnPosition)
virtual OUString GetCellText(sal_Int32 _nRow, sal_uInt16 _nColId) const override
GetCellText returns the text at the given position.
void AddCondition(const OTableFieldDescRef &rInfo, const OUString &rValue, const sal_uInt16 nLevel, bool _bAddOrOnOneLine)
void AddGroupBy(const OTableFieldDescRef &rInfo)
virtual OUString GetAccessibleObjectName(AccessibleBrowseBoxObjType eObjType, sal_Int32 _nPosition=-1) const override
return the name of the specified object.
OQueryDesignView * getDesignView()
virtual sal_uInt32 GetTotalCellWidth(sal_Int32 nRow, sal_uInt16 nColId) override
void DuplicateConditionLevel(const sal_uInt16 nLevel)
void CheckFreeColumns(sal_uInt16 &_rColumnPosition)
bool fillColumnRef(const ::connectivity::OSQLParseNode *_pColumnRef, const css::uno::Reference< css::sdbc::XConnection > &_rxConnection, OTableFieldDescRef const &_pEntry, bool &_bListAction)
uses the parse node to fill all information into the field
virtual void Command(const CommandEvent &rEvt) override
bool isCutAllowed() const
VclPtr< ::svt::CheckBoxControl > m_pVisibleCell
bool GetFunctionName(sal_uInt32 _nFunctionTokenId, OUString &rFkt)
void DeleteFields(const OUString &rAliasName)
void SetReadOnly(bool bRO)
void appendUndoAction(const OUString &_rOldValue, std::u16string_view _rNewValue, sal_Int32 _nRow, bool &_bListAction)
void EnterUndoMode()
Disables the generation of undo actions.
virtual void KeyInput(const KeyEvent &rEvt) override
OTableFields & getFields() const
virtual void GetFocus() override
void InsertColumn(const OTableFieldDescRef &pEntry, sal_uInt16 &_nColumnPosition)
bool isCopyAllowed() const
virtual void ColumnResized(sal_uInt16 nColId) override
void setFunctionCell(OTableFieldDescRef const &_pEntry)
remove or insert the necessary function types
sal_uInt16 m_nVisibleCount
VclPtr< ::svt::ListBoxControl > m_pTableCell
virtual bool SeekRow(sal_Int32 nRow) override
OUString m_aFunctionStrings
VclPtr< ::svt::ComboBoxControl > m_pFieldCell
bool HasFieldByAliasName(std::u16string_view rFieldName, OTableFieldDescRef const &rInfo) const
static void enableControl(const OTableFieldDescRef &_rEntry, Window *_pControl)
void setTextCellContext(const OTableFieldDescRef &_rEntry, const OUString &_sText, const OUString &_sHelpId)
virtual void MouseButtonUp(const BrowserMouseEvent &rEvt) override
virtual sal_Int8 AcceptDrop(const BrowserAcceptDropEvent &rEvt) override
DECL_LINK(OnInvalidateTimer, Timer *, void)
void LeaveUndoMode()
Enables the generation of undo actions.
virtual void dispose() override
virtual void PaintStatusCell(OutputDevice &rDev, const tools::Rectangle &rRect) const override
OUString GetCellContents(sal_Int32 nCellIndex, sal_uInt16 nColId)
void notifyTableFieldChanged(const OUString &_sOldAlias, std::u16string_view _sAlias, bool &_bListAction, sal_uInt16 _nColumnId)
append an undo action for the table field
void SetNoneVisibleRow(sal_Int32 nRows)
OTableFieldDescRef InsertField(const OTableFieldDescRef &rInfo, sal_uInt16 _nColumnPosition=BROWSER_INVALIDID, bool bVis=true, bool bActivate=true)
VclPtr< ::svt::ListBoxControl > m_pFunctionCell
OTableFieldDescRef const & AppendNewCol(sal_uInt16 nCnt=1)
std::vector< bool > m_bVisibleRow
VclPtr< ::svt::ListBoxControl > m_pOrderCell
OSelectionBrowseBox(vcl::Window *pParent)
virtual void InitController(::svt::CellControllerRef &rController, sal_Int32 nRow, sal_uInt16 nCol) override
virtual css::uno::Reference< css::accessibility::XAccessible > CreateAccessibleCell(sal_Int32 nRow, sal_uInt16 nColumnId) override
Creates the accessible object of a data table cell.
virtual sal_Int8 ExecuteDrop(const BrowserExecuteDropEvent &rEvt) override
virtual bool SaveModified() override
bool IsRowVisible(sal_uInt16 _nWhich) const
void invalidateUndoRedo()
void adjustSelectionMode(bool _bClickedOntoHeader, bool _bClickedOntoHandleCol)
Size CalcOptimalSize(const Size &_rAvailable)
void SetRowVisible(sal_uInt16 _nWhich, bool _bVis)
VclPtr< ::svt::EditControl > m_pTextCell
void AddOrder(const OTableFieldDescRef &rInfo, const EOrderDir eDir, sal_uInt32 _nCurrentPos)
sal_Int32 GetRealRow(sal_Int32 nRow) const
virtual ~OSelectionBrowseBox() override
virtual void ColumnMoved(sal_uInt16 nColId) override
void RemoveField(sal_uInt16 nId)
virtual void MouseButtonDown(const BrowserMouseEvent &rEvt) override
void notifyFunctionFieldChanged(const OUString &_sOldFunctionName, std::u16string_view _sFunctionName, bool &_bListAction, sal_uInt16 _nColumnId)
append an undo action for the function field
bool fillEntryTable(OTableFieldDescRef const &_pEntry, const OUString &_sTableName)
sets the table window at the _pEntry
virtual OUString GetRowDescription(sal_Int32 _nRow) const override
returns the description of the row.
sal_uInt32 m_nLastSortColumn
virtual void Init() override
bool fillColumnRef(const OUString &_sColumnName, std::u16string_view _sTableRange, const css::uno::Reference< css::sdbc::XDatabaseMetaData > &_xMetaData, OTableFieldDescRef const &_pEntry, bool &_bListAction)
bool isPasteAllowed() const
virtual void DeactivateCell(bool bUpdate=true) override
void clearEntryFunctionField(std::u16string_view _sFieldName, OTableFieldDescRef const &_pEntry, bool &_bListAction, sal_uInt16 _nColumnId)
clears the function fields of the submitted entry if it doesn't match the SQL standard and append an ...
virtual void PaintCell(OutputDevice &rDev, const tools::Rectangle &rRect, sal_uInt16 nColumnId) const override
OTableFieldDescRef getEntry(OTableFields::size_type _nPos)
std::vector< OTableFieldDescRef > OTableFields