LibreOffice Module extensions (master) 1
toolbar.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19
20#include <sal/config.h>
21
24#include <com/sun/star/frame/XDispatch.hpp>
25#include <com/sun/star/frame/XDispatchProvider.hpp>
26#include <com/sun/star/util/URLTransformer.hpp>
27#include <com/sun/star/util/XURLTransformer.hpp>
28#include <com/sun/star/frame/FrameSearchFlag.hpp>
29#include "datman.hxx"
30#include "toolbar.hxx"
31#include <o3tl/any.hxx>
32#include <svtools/miscopt.hxx>
33#include <svtools/imgdef.hxx>
34#include <utility>
35#include <vcl/svapp.hxx>
36#include <vcl/settings.hxx>
37#include <vcl/mnemonic.hxx>
38#include <vcl/event.hxx>
39#include <vcl/weldutils.hxx>
40#include <bitmaps.hlst>
41
42#include "bibtools.hxx"
43
44using namespace ::com::sun::star;
45using namespace ::com::sun::star::uno;
46using namespace ::com::sun::star::beans;
47
48
49// Constants --------------------------------------------------------------
50
51
53 nIndex(nId),
54 aCommand(std::move(aStr)),
55 pToolBar(pTB)
56{
57}
58
60{
61}
62
63void BibToolBarListener::statusChanged(const css::frame::FeatureStateEvent& rEvt)
64{
65 if(rEvt.FeatureURL.Complete == aCommand)
66 {
67 SolarMutexGuard aGuard;
68 pToolBar->EnableItem(nIndex,rEvt.IsEnabled);
69
70 css::uno::Any aState=rEvt.State;
71 if(auto bChecked = o3tl::tryAccess<bool>(aState))
72 {
73 pToolBar->CheckItem(nIndex, *bChecked);
74 }
75
76 }
77};
78
79
82{
83}
84
86{
87}
88
89void BibTBListBoxListener::statusChanged(const css::frame::FeatureStateEvent& rEvt)
90{
91 if(rEvt.FeatureURL.Complete != GetCommand())
92 return;
93
94 SolarMutexGuard aGuard;
95 pToolBar->EnableSourceList(rEvt.IsEnabled);
96
97 Any aState = rEvt.State;
98 if(auto pStringSeq = o3tl::tryAccess<Sequence<OUString>>(aState))
99 {
100 pToolBar->UpdateSourceList(false);
101 pToolBar->ClearSourceList();
102
103 const OUString* pStringArray = pStringSeq->getConstArray();
104
105 sal_uInt32 nCount = pStringSeq->getLength();
106 OUString aEntry;
107 for( sal_uInt32 i=0; i<nCount; i++ )
108 {
109 aEntry = pStringArray[i];
110 pToolBar->InsertSourceEntry(aEntry);
111 }
112 pToolBar->UpdateSourceList(true);
113 }
114
115 pToolBar->SelectSourceEntry(rEvt.FeatureDescriptor);
116};
117
120{
121}
122
124{
125}
126
127void BibTBQueryMenuListener::statusChanged(const frame::FeatureStateEvent& rEvt)
128{
129 if(rEvt.FeatureURL.Complete != GetCommand())
130 return;
131
132 SolarMutexGuard aGuard;
133 pToolBar->EnableSourceList(rEvt.IsEnabled);
134
135 uno::Any aState=rEvt.State;
136 auto pStringSeq = o3tl::tryAccess<Sequence<OUString>>(aState);
137 if(!pStringSeq)
138 return;
139
140 pToolBar->ClearFilterMenu();
141
142 const OUString* pStringArray = pStringSeq->getConstArray();
143
144 sal_uInt32 nCount = pStringSeq->getLength();
145 for( sal_uInt32 i=0; i<nCount; i++ )
146 {
147 sal_uInt16 nID = pToolBar->InsertFilterItem(pStringArray[i]);
148 if(pStringArray[i]==rEvt.FeatureDescriptor)
149 {
150 pToolBar->SelectFilterItem(nID);
151 }
152 }
153};
154
157{
158}
159
161{
162}
163
164void BibTBEditListener::statusChanged(const frame::FeatureStateEvent& rEvt)
165{
166 if(rEvt.FeatureURL.Complete == GetCommand())
167 {
168 SolarMutexGuard aGuard;
169 pToolBar->EnableQuery(rEvt.IsEnabled);
170
171 uno::Any aState=rEvt.State;
172 if(auto aStr = o3tl::tryAccess<OUString>(aState))
173 {
174 pToolBar->SetQueryString(*aStr);
175 }
176 }
177}
178
180 : InterimItemWindow(pParent, "modules/sbibliography/ui/combobox.ui", "ComboBox")
181 , m_xFtSource(m_xBuilder->weld_label("label"))
182 , m_xLBSource(m_xBuilder->weld_combo_box("combobox"))
183{
184 m_xFtSource->set_toolbar_background();
185 m_xLBSource->set_toolbar_background();
186 m_xLBSource->set_size_request(100, -1);
188}
189
191{
192 m_xLBSource.reset();
193 m_xFtSource.reset();
195}
196
198{
199 disposeOnce();
200}
201
203 : InterimItemWindow(pParent, "modules/sbibliography/ui/editbox.ui", "EditBox")
204 , m_xFtQuery(m_xBuilder->weld_label("label"))
205 , m_xEdQuery(m_xBuilder->weld_entry("entry"))
206{
207 m_xFtQuery->set_toolbar_background();
208 m_xEdQuery->set_toolbar_background();
209 m_xEdQuery->set_size_request(100, -1);
211}
212
214{
215 m_xEdQuery.reset();
216 m_xFtQuery.reset();
218}
219
221{
222 disposeOnce();
223}
224
226 : ToolBox(pParent, "toolbar", "modules/sbibliography/ui/toolbar.ui")
227 , aIdle("BibToolBar")
228 , xSource(VclPtr<ComboBoxControl>::Create(this))
229 , pLbSource(xSource->get_widget())
230 , xQuery(VclPtr<EditControl>::Create(this))
231 , pEdQuery(xQuery->get_widget())
232 , xBuilder(Application::CreateBuilder(nullptr, "modules/sbibliography/ui/autofiltermenu.ui"))
233 , xPopupMenu(xBuilder->weld_menu("menu"))
234 , nMenuId(0)
235 , aLayoutManager(aLink)
236 , nSymbolsSize(SFX_SYMBOLS_SIZE_SMALL)
237{
239
240 xSource->Show();
241 pLbSource->connect_changed(LINK( this, BibToolBar, SelHdl));
242
243 SvtMiscOptions().AddListenerLink( LINK( this, BibToolBar, OptionsChanged_Impl ) );
244 Application::AddEventListener( LINK( this, BibToolBar, SettingsChanged_Impl ) );
245
246 aIdle.SetInvokeHandler(LINK( this, BibToolBar, SendSelHdl));
247 aIdle.SetPriority(TaskPriority::LOWEST);
248
249 SetDropdownClickHdl( LINK( this, BibToolBar, MenuHdl));
250
251 xQuery->Show();
252
253 nTBC_SOURCE = GetItemId(".uno:Bib/source");
254 nTBC_QUERY = GetItemId(".uno:Bib/query");
255 nTBC_BT_AUTOFILTER = GetItemId(".uno:Bib/autoFilter");
256 nTBC_BT_COL_ASSIGN = GetItemId("TBC_BT_COL_ASSIGN");
257 nTBC_BT_CHANGESOURCE = GetItemId(".uno:Bib/sdbsource");
258 nTBC_BT_FILTERCRIT = GetItemId(".uno:Bib/standardFilter");
259 nTBC_BT_REMOVEFILTER = GetItemId(".uno:Bib/removeFilter");
260
263
265
267}
268
270{
271 disposeOnce();
272}
273
275{
276 SvtMiscOptions().RemoveListenerLink( LINK( this, BibToolBar, OptionsChanged_Impl ) );
277 Application::RemoveEventListener( LINK( this, BibToolBar, SettingsChanged_Impl ) );
279 pEdQuery = nullptr;
281 pLbSource = nullptr;
283 xPopupMenu.reset();
284 xBuilder.reset();
286}
287
289{
290 ToolBox::ImplToolItems::size_type nCount=GetItemCount();
291
292 uno::Reference< frame::XDispatch > xDisp(xController,UNO_QUERY);
293 uno::Reference< util::XURLTransformer > xTrans( util::URLTransformer::create(comphelper::getProcessComponentContext()) );
294 if( !xTrans.is() )
295 return;
296
297 util::URL aQueryURL;
298 aQueryURL.Complete = ".uno:Bib/MenuFilter";
299 xTrans->parseStrict( aQueryURL);
301 xDisp->addStatusListener(pQuery, aQueryURL);
302
303 for(ToolBox::ImplToolItems::size_type nPos=0;nPos<nCount;nPos++)
304 {
306 if (!nId)
307 continue;
308
309 util::URL aURL;
310 aURL.Complete = GetItemCommand(nId);
311 if(aURL.Complete.isEmpty())
312 continue;
313
314 xTrans->parseStrict( aURL );
315
316 css::uno::Reference< css::frame::XStatusListener> xListener;
317 if (nId == nTBC_SOURCE)
318 {
319 xListener=new BibTBListBoxListener(this,aURL.Complete,nId);
320 }
321 else if (nId == nTBC_QUERY)
322 {
323 xListener=new BibTBEditListener(this,aURL.Complete,nId);
324 }
325 else
326 {
327 xListener=new BibToolBarListener(this,aURL.Complete,nId);
328 }
329
330 aListenerArr.push_back( xListener );
331 xDisp->addStatusListener(xListener,aURL);
332 }
333}
334
335void BibToolBar::SetXController(const uno::Reference< frame::XController > & xCtr)
336{
337 xController=xCtr;
338 InitListener();
339
340}
341
343{
345
346 if (nId != nTBC_BT_AUTOFILTER)
347 {
348 SendDispatch(nId,Sequence<PropertyValue>() );
349 }
350 else
351 {
352 Sequence<PropertyValue> aPropVal
353 {
356 };
357 SendDispatch(nId,aPropVal);
358 }
359}
360
361void BibToolBar::SendDispatch(ToolBoxItemId nId, const Sequence< PropertyValue >& rArgs)
362{
363 OUString aCommand = GetItemCommand(nId);
364
365 uno::Reference< frame::XDispatchProvider > xDSP( xController, UNO_QUERY );
366
367 if( !xDSP.is() || aCommand.isEmpty() )
368 return;
369
370 uno::Reference< util::XURLTransformer > xTrans( util::URLTransformer::create(comphelper::getProcessComponentContext()) );
371 if( !xTrans.is() )
372 return;
373
374 // load the file
375 util::URL aURL;
376 aURL.Complete = aCommand;
377
378 xTrans->parseStrict( aURL );
379
380 uno::Reference< frame::XDispatch > xDisp = xDSP->queryDispatch( aURL, OUString(), frame::FrameSearchFlag::SELF );
381
382 if ( xDisp.is() )
383 xDisp->dispatch( aURL, rArgs);
384
385}
386
388{
390
391 vcl::Window* pWin = GetParent();
392
393 if (nId == nTBC_BT_COL_ASSIGN )
394 {
395 if (pDatMan)
396 pDatMan->CreateMappingDialog(pWin ? pWin->GetFrameWeld() : nullptr);
397 CheckItem( nId, false );
398 }
399 else if (nId == nTBC_BT_CHANGESOURCE)
400 {
401 if (pDatMan)
402 {
403 OUString sNew = pDatMan->CreateDBChangeDialog(pWin ? pWin->GetFrameWeld() : nullptr);
404 if (!sNew.isEmpty())
406 }
407 CheckItem( nId, false );
408 }
409}
410
412{
413 xPopupMenu->clear();
414 nMenuId=0;
415}
416
417sal_uInt16 BibToolBar::InsertFilterItem(const OUString& rMenuEntry)
418{
419 nMenuId++;
420 xPopupMenu->append_check(OUString::number(nMenuId), rMenuEntry);
421 return nMenuId;
422}
423
425{
426 OUString sId = OUString::number(nId);
427 xPopupMenu->set_active(sId, true);
430}
431
433{
434 xSource->set_sensitive(bFlag);
435}
436
438{
439 pLbSource->clear();
440}
441
443{
444 if (bFlag)
445 pLbSource->thaw();
446 else
447 pLbSource->freeze();
448}
449
450void BibToolBar::InsertSourceEntry(const OUString& aEntry)
451{
452 pLbSource->append_text(aEntry);
453}
454
455void BibToolBar::SelectSourceEntry(const OUString& aStr)
456{
458}
459
461{
462 xQuery->set_sensitive(bFlag);
463}
464
465void BibToolBar::SetQueryString(const OUString& aStr)
466{
468}
469
471{
472 bool bResult = true;
473
474 NotifyEventType nSwitch=rNEvt.GetType();
475 if (pEdQuery && pEdQuery->has_focus() && nSwitch == NotifyEventType::KEYINPUT)
476 {
477 const vcl::KeyCode& aKeyCode=rNEvt.GetKeyEvent()->GetKeyCode();
478 sal_uInt16 nKey = aKeyCode.GetCode();
479 if(nKey == KEY_RETURN)
480 {
481 Sequence<PropertyValue> aPropVal
482 {
485 };
487 return bResult;
488 }
489
490 }
491
492 bResult=ToolBox::PreNotify(rNEvt);
493
494 return bResult;
495}
496
498{
499 aIdle.Start();
500}
501
502IMPL_LINK_NOARG( BibToolBar, SendSelHdl, Timer*, void )
503{
504 Sequence<PropertyValue> aPropVal
505 {
506 comphelper::makePropertyValue("DataSourceName", MnemonicGenerator::EraseAllMnemonicChars( pLbSource->get_active_text() ))
507 };
508 SendDispatch(nTBC_SOURCE, aPropVal);
509}
510
512{
513 ToolBoxItemId nId = GetCurItemId();
514 if (nId != nTBC_BT_AUTOFILTER)
515 return;
516
517 EndSelection(); // before SetDropMode (SetDropMode calls SetItemImage)
518
519 SetItemDown(nTBC_BT_AUTOFILTER, true);
520
521 tools::Rectangle aRect(GetItemRect(nTBC_BT_AUTOFILTER));
522 weld::Window* pParent = weld::GetPopupParent(*this, aRect);
523 OUString sId = xPopupMenu->popup_at_rect(pParent, aRect);
524
525 if (!sId.isEmpty())
526 {
527 xPopupMenu->set_active(sSelMenuItem, false);
528 xPopupMenu->set_active(sId, true);
529 sSelMenuItem = sId;
530 aQueryField = MnemonicGenerator::EraseAllMnemonicChars(xPopupMenu->get_label(sId));
531 Sequence<PropertyValue> aPropVal
532 {
533 comphelper::makePropertyValue("QueryText", pEdQuery->get_text()),
534 comphelper::makePropertyValue("QueryField", aQueryField)
535 };
536 SendDispatch(nTBC_BT_AUTOFILTER, aPropVal);
537 }
538
539 MouseEvent aLeave( Point(), 0, MouseEventModifiers::LEAVEWINDOW | MouseEventModifiers::SYNTHETIC );
540 MouseMove( aLeave );
541 SetItemDown(nTBC_BT_AUTOFILTER, false);
542}
543
544void BibToolBar::statusChanged(const frame::FeatureStateEvent& rEvent)
545{
546 for(uno::Reference<frame::XStatusListener> & rListener : aListenerArr)
547 {
548 rListener->statusChanged(rEvent);
549 }
550}
551
553{
554 if ( (rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
555 (rDCEvt.GetFlags() & AllSettingsFlags::STYLE) )
557 ToolBox::DataChanged( rDCEvt );
558}
559
560IMPL_LINK_NOARG( BibToolBar, OptionsChanged_Impl, LinkParamNone*, void )
561{
562 bool bRebuildToolBar = false;
563 sal_Int16 eSymbolsSize = SvtMiscOptions::GetCurrentSymbolsSize();
564 if ( nSymbolsSize != eSymbolsSize )
565 {
566 nSymbolsSize = eSymbolsSize;
567 bRebuildToolBar = true;
568 }
569
570 if ( bRebuildToolBar )
571 RebuildToolbar();
572}
573
574IMPL_LINK_NOARG( BibToolBar, SettingsChanged_Impl, VclSimpleEvent&, void )
575{
576 // Check if toolbar button size have changed and we have to use system settings
577 sal_Int16 eSymbolsSize = SvtMiscOptions::GetCurrentSymbolsSize();
578 if ( eSymbolsSize != nSymbolsSize )
579 {
580 nSymbolsSize = eSymbolsSize;
581 RebuildToolbar();
582 }
583}
584
586{
588 // We have to call parent asynchronously as SetSize works also asynchronously!
590}
591
593{
594 SetItemImage(nTBC_BT_AUTOFILTER, Image(StockImage::Yes, nSymbolsSize == SFX_SYMBOLS_SIZE_SMALL ? OUString(RID_EXTBMP_AUTOFILTER_SC) : OUString(RID_EXTBMP_AUTOFILTER_LC)));
595 SetItemImage(nTBC_BT_FILTERCRIT, Image(StockImage::Yes, nSymbolsSize == SFX_SYMBOLS_SIZE_SMALL ? OUString(RID_EXTBMP_FILTERCRIT_SC) : OUString(RID_EXTBMP_FILTERCRIT_LC)));
596 SetItemImage(nTBC_BT_REMOVEFILTER, Image(StockImage::Yes, nSymbolsSize == SFX_SYMBOLS_SIZE_SMALL ? OUString(RID_EXTBMP_REMOVE_FILTER_SORT_SC) : OUString(RID_EXTBMP_REMOVE_FILTER_SORT_LC)));
598}
599
601{
602 Size aOldSize = GetSizePixel();
603 Size aSize = CalcWindowSizePixel();
604 if ( !aSize.Width() )
605 aSize.setWidth( aOldSize.Width() );
606 else if ( !aSize.Height() )
607 aSize.setHeight( aOldSize.Height() );
608
609 Size aTbSize = GetSizePixel();
610 if (
611 (aSize.Width() && aSize.Width() != aTbSize.Width()) ||
612 (aSize.Height() && aSize.Height() != aTbSize.Height())
613 )
614 {
615 SetPosSizePixel( GetPosPixel(), aSize );
616 Invalidate();
617 }
618}
619
620/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
static void AddEventListener(const Link< VclSimpleEvent &, void > &rEventListener)
static ImplSVEvent * PostUserEvent(const Link< void *, void > &rLink, void *pCaller=nullptr, bool bReferenceLink=false)
static void RemoveEventListener(const Link< VclSimpleEvent &, void > &rEventListener)
void CreateMappingDialog(weld::Window *pParent)
Definition: datman.cxx:1306
OUString CreateDBChangeDialog(weld::Window *pParent)
Definition: datman.cxx:1315
void setActiveDataSource(const OUString &rURL)
Definition: datman.cxx:859
virtual ~BibTBEditListener() override
Definition: toolbar.cxx:160
virtual void SAL_CALL statusChanged(const css::frame::FeatureStateEvent &Event) override
Definition: toolbar.cxx:164
BibTBEditListener(BibToolBar *pTB, const OUString &aStr, ToolBoxItemId nId)
Definition: toolbar.cxx:155
virtual void SAL_CALL statusChanged(const css::frame::FeatureStateEvent &Event) override
Definition: toolbar.cxx:89
BibTBListBoxListener(BibToolBar *pTB, const OUString &aStr, ToolBoxItemId nId)
Definition: toolbar.cxx:80
virtual ~BibTBListBoxListener() override
Definition: toolbar.cxx:85
virtual ~BibTBQueryMenuListener() override
Definition: toolbar.cxx:123
virtual void SAL_CALL statusChanged(const css::frame::FeatureStateEvent &Event) override
Definition: toolbar.cxx:127
BibTBQueryMenuListener(BibToolBar *pTB, const OUString &aStr, ToolBoxItemId nId)
Definition: toolbar.cxx:118
ToolBoxItemId nIndex
Definition: toolbar.hxx:38
virtual ~BibToolBarListener() override
Definition: toolbar.cxx:59
OUString aCommand
Definition: toolbar.hxx:39
BibToolBarListener(BibToolBar *pTB, OUString aStr, ToolBoxItemId nId)
Definition: toolbar.cxx:52
VclPtr< BibToolBar > pToolBar
Definition: toolbar.hxx:43
const OUString & GetCommand() const
Definition: toolbar.hxx:50
virtual void SAL_CALL statusChanged(const css::frame::FeatureStateEvent &Event) override
Definition: toolbar.cxx:63
Link< void *, void > aLayoutManager
Definition: toolbar.hxx:155
void SelectSourceEntry(const OUString &)
Definition: toolbar.cxx:455
ToolBoxItemId nTBC_BT_AUTOFILTER
Definition: toolbar.hxx:160
std::unique_ptr< weld::Builder > xBuilder
Definition: toolbar.hxx:150
virtual void Select() override
Definition: toolbar.cxx:342
BibToolBarListenerArr aListenerArr
Definition: toolbar.hxx:143
weld::ComboBox * pLbSource
Definition: toolbar.hxx:147
void RebuildToolbar()
Definition: toolbar.cxx:585
void ApplyImageList()
Definition: toolbar.cxx:592
ToolBoxItemId nTBC_BT_CHANGESOURCE
Definition: toolbar.hxx:162
void EnableSourceList(bool bFlag)
Definition: toolbar.cxx:432
ToolBoxItemId nTBC_SOURCE
Definition: toolbar.hxx:158
void statusChanged(const css::frame::FeatureStateEvent &Event)
Definition: toolbar.cxx:544
BibToolBar(vcl::Window *pParent, Link< void *, void > aLink)
Definition: toolbar.cxx:225
virtual ~BibToolBar() override
Definition: toolbar.cxx:269
sal_uInt16 nMenuId
Definition: toolbar.hxx:152
ToolBoxItemId nTBC_BT_COL_ASSIGN
Definition: toolbar.hxx:161
void ClearFilterMenu()
Definition: toolbar.cxx:411
ToolBoxItemId nTBC_BT_FILTERCRIT
Definition: toolbar.hxx:163
void DataChanged(const DataChangedEvent &rDCEvt) override
Definition: toolbar.cxx:552
VclPtr< EditControl > xQuery
Definition: toolbar.hxx:148
Idle aIdle
Definition: toolbar.hxx:145
std::unique_ptr< weld::Menu > xPopupMenu
Definition: toolbar.hxx:151
void SendDispatch(ToolBoxItemId nId, const css::uno::Sequence< css::beans::PropertyValue > &rArgs)
Definition: toolbar.cxx:361
void InsertSourceEntry(const OUString &)
Definition: toolbar.cxx:450
void ClearSourceList()
Definition: toolbar.cxx:437
css::uno::Reference< css::frame::XController > xController
Definition: toolbar.hxx:144
void SetXController(const css::uno::Reference< css::frame::XController > &)
Definition: toolbar.cxx:335
VclPtr< ComboBoxControl > xSource
Definition: toolbar.hxx:146
OUString sSelMenuItem
Definition: toolbar.hxx:153
void AdjustToolBox()
Definition: toolbar.cxx:600
virtual void Click() override
Definition: toolbar.cxx:387
void SelectFilterItem(sal_uInt16 nId)
Definition: toolbar.cxx:424
sal_Int16 nSymbolsSize
Definition: toolbar.hxx:156
BibDataManager * pDatMan
Definition: toolbar.hxx:166
OUString aQueryField
Definition: toolbar.hxx:154
void UpdateSourceList(bool bFlag)
Definition: toolbar.cxx:442
ToolBoxItemId nTBC_BT_REMOVEFILTER
Definition: toolbar.hxx:164
weld::Entry * pEdQuery
Definition: toolbar.hxx:149
virtual bool PreNotify(NotifyEvent &rNEvt) override
Definition: toolbar.cxx:470
void EnableQuery(bool bFlag)
Definition: toolbar.cxx:460
void InitListener()
Definition: toolbar.cxx:288
sal_uInt16 InsertFilterItem(const OUString &)
Definition: toolbar.cxx:417
virtual void dispose() override
Definition: toolbar.cxx:274
ToolBoxItemId nTBC_QUERY
Definition: toolbar.hxx:159
void SetQueryString(const OUString &)
Definition: toolbar.cxx:465
ComboBoxControl(vcl::Window *pParent)
Definition: toolbar.cxx:179
std::unique_ptr< weld::ComboBox > m_xLBSource
Definition: toolbar.hxx:115
std::unique_ptr< weld::Label > m_xFtSource
Definition: toolbar.hxx:114
virtual void dispose() override
Definition: toolbar.cxx:190
virtual ~ComboBoxControl() override
Definition: toolbar.cxx:197
DataChangedEventType GetType() const
AllSettingsFlags GetFlags() const
Point GetPosPixel() const override
Size GetSizePixel() const override
std::unique_ptr< weld::Label > m_xFtQuery
Definition: toolbar.hxx:135
virtual void dispose() override
Definition: toolbar.cxx:213
std::unique_ptr< weld::Entry > m_xEdQuery
Definition: toolbar.hxx:136
EditControl(vcl::Window *pParent)
Definition: toolbar.cxx:202
virtual ~EditControl() override
Definition: toolbar.cxx:220
virtual void dispose() override
const vcl::KeyCode & GetKeyCode() const
static OUString EraseAllMnemonicChars(const OUString &rStr)
const KeyEvent * GetKeyEvent() const
NotifyEventType GetType() const
constexpr tools::Long Height() const
void setWidth(tools::Long nWidth)
void setHeight(tools::Long nHeight)
constexpr tools::Long Width() const
static sal_Int16 GetCurrentSymbolsSize()
void RemoveListenerLink(const Link< LinkParamNone *, void > &rLink)
void AddListenerLink(const Link< LinkParamNone *, void > &rLink)
void SetPriority(TaskPriority ePriority)
void SetInvokeHandler(const Link< Timer *, void > &rLink)
ToolBoxItemId GetItemId(ImplToolItems::size_type nPos) const
void SetDropdownClickHdl(const Link< ToolBox *, void > &rLink)
virtual void DataChanged(const DataChangedEvent &rDCEvt) override
OUString GetItemCommand(ToolBoxItemId nItemId) const
Size CalcWindowSizePixel()
virtual void dispose() override
void CheckItem(ToolBoxItemId nItemId, bool bCheck=true)
ImplToolItems::size_type GetItemCount() const
void SetItemWindow(ToolBoxItemId nItemId, vcl::Window *pNewWindow)
ToolBoxItemId GetCurItemId() const
void SetItemImage(ToolBoxItemId nItemId, const Image &rImage)
void disposeAndClear()
reference_type * get() const
sal_uInt16 GetCode() const
vcl::Window * GetParent() const
virtual void SetSizePixel(const Size &rNewSize)
Size get_preferred_size() const
virtual bool PreNotify(NotifyEvent &rNEvt)
void Invalidate(InvalidateFlags nFlags=InvalidateFlags::NONE)
weld::Window * GetFrameWeld() const
virtual void SetPosSizePixel(const Point &rNewPos, const Size &rNewSize)
virtual void clear()=0
void append_text(const OUString &rStr)
void set_active_text(const OUString &rStr)
void connect_changed(const Link< ComboBox &, void > &rLink)
virtual void set_text(const OUString &rText)=0
virtual OUString get_text() const=0
virtual void freeze()=0
virtual void thaw()=0
virtual bool has_focus() const=0
int nCount
URL aURL
NotifyEventType
SFX_SYMBOLS_SIZE_SMALL
sal_Int32 nIndex
constexpr sal_uInt16 KEY_RETURN
sal_uInt16 nPos
aStr
void AddToTaskPaneList(vcl::Window *pWindowToBeHandled)
Definition: bibtools.hxx:31
void RemoveFromTaskPaneList(vcl::Window *pWindowToBeHandled)
Definition: bibtools.hxx:36
Reference< XComponentContext > getProcessComponentContext()
css::beans::PropertyValue makePropertyValue(const OUString &rName, T &&rValue)
int i
void Create(SwFormatVertOrient &rItem, SvStream &rStrm, sal_uInt16 nVersionAbusedAsSize)
detail::Optional< bool >::type tryAccess< bool >(css::uno::Any const &any)
std::enable_if<!(detail::IsDerivedReference< T >::value||detail::IsUnoSequenceType< T >::value||std::is_base_of< css::uno::XInterface, T >::value), typenamedetail::Optional< T >::type >::type tryAccess(css::uno::Any const &any)
weld::Window * GetPopupParent(vcl::Window &rOutWin, tools::Rectangle &rRect)
sal_Int16 nId
IMPL_LINK_NOARG(BibToolBar, SelHdl, weld::ComboBox &, void)
Definition: toolbar.cxx:497
OUString aCommand
OUString sId