LibreOffice Module vcl (master)  1
dockwin.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 <tools/time.hxx>
21 #include <sal/log.hxx>
22 #include <vcl/accel.hxx>
23 #include <vcl/event.hxx>
24 #include <vcl/floatwin.hxx>
25 #include <vcl/dockwin.hxx>
26 #include <vcl/layout.hxx>
27 #include <vcl/svapp.hxx>
28 #include <vcl/timer.hxx>
29 #include <vcl/idle.hxx>
30 #include <vcl/settings.hxx>
31 
32 #include <svdata.hxx>
33 #include <window.h>
34 #include <brdwin.hxx>
35 
36 #define DOCKWIN_FLOATSTYLES (WB_SIZEABLE | WB_MOVEABLE | WB_CLOSEABLE | WB_STANDALONE | WB_ROLLABLE )
37 
39 {
40 public:
41  ImplData();
42 
45 };
46 
48 {
49  mpParent = nullptr;
50  maMaxOutSize = Size( SHRT_MAX, SHRT_MAX );
51 }
52 
53 namespace {
54 
55 class ImplDockFloatWin : public FloatingWindow
56 {
57 private:
58  VclPtr<DockingWindow> mpDockWin;
59  sal_uInt64 mnLastTicks;
60  Idle maDockIdle;
62  tools::Rectangle maDockRect;
63  bool mbInMove;
64  ImplSVEvent * mnLastUserEvent;
65 
66  DECL_LINK(DockingHdl, void *, void);
67  DECL_LINK(DockTimerHdl, Timer *, void);
68 public:
69  ImplDockFloatWin( vcl::Window* pParent, WinBits nWinBits,
70  DockingWindow* pDockingWin );
71  virtual ~ImplDockFloatWin() override;
72  virtual void dispose() override;
73 
74  virtual void Move() override;
75  virtual void Resize() override;
76  virtual void Resizing( Size& rSize ) override;
77  virtual bool Close() override;
78 };
79 
80 }
81 
82 ImplDockFloatWin::ImplDockFloatWin( vcl::Window* pParent, WinBits nWinBits,
83  DockingWindow* pDockingWin ) :
84  FloatingWindow( pParent, nWinBits ),
85  mpDockWin( pDockingWin ),
86  mnLastTicks( tools::Time::GetSystemTicks() ),
87  mbInMove( false ),
88  mnLastUserEvent( nullptr )
89 {
90  // copy settings of DockingWindow
91  if ( pDockingWin )
92  {
93  SetSettings( pDockingWin->GetSettings() );
94  Enable( pDockingWin->IsEnabled(), false );
95  EnableInput( pDockingWin->IsInputEnabled(), false );
96  AlwaysEnableInput( pDockingWin->IsAlwaysEnableInput(), false );
97  EnableAlwaysOnTop( pDockingWin->IsAlwaysOnTopEnabled() );
98  SetActivateMode( pDockingWin->GetActivateMode() );
99  }
100 
101  SetBackground();
102 
103  maDockIdle.SetInvokeHandler( LINK( this, ImplDockFloatWin, DockTimerHdl ) );
104  maDockIdle.SetPriority( TaskPriority::HIGH_IDLE );
105  maDockIdle.SetDebugName( "vcl::ImplDockFloatWin maDockIdle" );
106 }
107 
108 ImplDockFloatWin::~ImplDockFloatWin()
109 {
110  disposeOnce();
111 }
112 
113 void ImplDockFloatWin::dispose()
114 {
115  if( mnLastUserEvent )
116  Application::RemoveUserEvent( mnLastUserEvent );
117 
118  disposeBuilder();
119 
120  mpDockWin.clear();
122 }
123 
124 IMPL_LINK_NOARG(ImplDockFloatWin, DockTimerHdl, Timer *, void)
125 {
126  SAL_WARN_IF( !mpDockWin->IsFloatingMode(), "vcl", "docktimer called but not floating" );
127 
128  maDockIdle.Stop();
129  PointerState aState = GetPointerState();
130 
131  if( aState.mnState & KEY_MOD1 )
132  {
133  // i43499 CTRL disables docking now
134  mpDockWin->GetParent()->ImplGetFrameWindow()->HideTracking();
135  mpDockWin->EndDocking( maDockRect, true );
136  if( aState.mnState & ( MOUSE_LEFT | MOUSE_MIDDLE | MOUSE_RIGHT ) )
137  maDockIdle.Start();
138  }
139  else if( ! ( aState.mnState & ( MOUSE_LEFT | MOUSE_MIDDLE | MOUSE_RIGHT ) ) )
140  {
141  mpDockWin->GetParent()->ImplGetFrameWindow()->HideTracking();
142  mpDockWin->EndDocking( maDockRect, false );
143  }
144  else
145  {
146  mpDockWin->GetParent()->ImplGetFrameWindow()->ShowTracking( maDockRect, ShowTrackFlags::Big | ShowTrackFlags::TrackWindow );
147  maDockIdle.Start();
148  }
149 }
150 
151 IMPL_LINK_NOARG(ImplDockFloatWin, DockingHdl, void*, void)
152 {
153  PointerState aState = mpDockWin->GetParent()->GetPointerState();
154 
155  mnLastUserEvent = nullptr;
156  if( mpDockWin->IsDockable() &&
157  (tools::Time::GetSystemTicks() - mnLastTicks > 500) &&
158  ( aState.mnState & ( MOUSE_LEFT | MOUSE_MIDDLE | MOUSE_RIGHT ) ) &&
159  !(aState.mnState & KEY_MOD1) ) // i43499 CTRL disables docking now
160  {
161  maDockPos = mpDockWin->GetParent()->AbsoluteScreenToOutputPixel( OutputToAbsoluteScreenPixel( Point() ) );
162  maDockPos = mpDockWin->GetParent()->OutputToScreenPixel( maDockPos ); // sfx expects screen coordinates
163 
164  if( ! mpDockWin->IsDocking() )
165  mpDockWin->StartDocking();
166  maDockRect = tools::Rectangle( maDockPos, mpDockWin->GetSizePixel() );
167 
168  // mouse pos also in screen pixels
169  Point aMousePos = mpDockWin->GetParent()->OutputToScreenPixel( aState.maPos );
170 
171  bool bFloatMode = mpDockWin->Docking( aMousePos, maDockRect );
172  if( ! bFloatMode )
173  {
174  mpDockWin->GetParent()->ImplGetFrameWindow()->ShowTracking( maDockRect, ShowTrackFlags::Object | ShowTrackFlags::TrackWindow );
175  DockTimerHdl( nullptr );
176  }
177  else
178  {
179  mpDockWin->GetParent()->ImplGetFrameWindow()->HideTracking();
180  maDockIdle.Stop();
181  mpDockWin->EndDocking( maDockRect, true );
182  }
183  }
184  mbInMove = false;
185 }
186 
187 void ImplDockFloatWin::Move()
188 {
189  if( mbInMove )
190  return;
191 
192  mbInMove = true;
194  mpDockWin->Move();
195 
196  /*
197  * note: the window should only dock if
198  * the user releases all mouse buttons. The real problem here
199  * is that we don't get mouse events (at least not on X)
200  * if the mouse is on the decoration. So we have to start an
201  * awkward timer based process that polls the modifier/buttons
202  * to see whether they are in the right condition shortly after the
203  * last Move message.
204  */
205  if( ! mnLastUserEvent )
206  mnLastUserEvent = Application::PostUserEvent( LINK( this, ImplDockFloatWin, DockingHdl ), nullptr, true );
207 }
208 
209 void ImplDockFloatWin::Resize()
210 {
212  Size aSize( GetSizePixel() );
213  mpDockWin->ImplPosSizeWindow( 0, 0, aSize.Width(), aSize.Height(), PosSizeFlags::PosSize );
214 }
215 
216 void ImplDockFloatWin::Resizing( Size& rSize )
217 {
218  FloatingWindow::Resizing( rSize );
219  mpDockWin->Resizing( rSize );
220 }
221 
222 bool ImplDockFloatWin::Close()
223 {
224  return mpDockWin->Close();
225 }
226 
227 void DockingWindow::ImplStartDocking( const Point& rPos )
228 {
229  if ( !mbDockable )
230  return;
231 
232  maMouseOff = rPos;
233  mbDocking = true;
236 
237  // calculate FloatingBorder
239  if ( mpFloatWin )
240  pWin = mpFloatWin;
241  else
242  pWin = VclPtr<ImplDockFloatWin>::Create( mpImplData->mpParent, mnFloatBits, nullptr );
244  if ( !mpFloatWin )
245  pWin.disposeAndClear();
246 
247  Point aPos = ImplOutputToFrame( Point() );
248  Size aSize = Window::GetOutputSizePixel();
249  mnTrackX = aPos.X();
250  mnTrackY = aPos.Y();
251  mnTrackWidth = aSize.Width();
252  mnTrackHeight = aSize.Height();
253 
254  if ( mbLastFloatMode )
255  {
256  maMouseOff.AdjustX(mnDockLeft );
257  maMouseOff.AdjustY(mnDockTop );
258  mnTrackX -= mnDockLeft;
259  mnTrackY -= mnDockTop;
262  }
263 
264  if ( GetSettings().GetStyleSettings().GetDragFullOptions() & DragFullOptions::Docking &&
265  !( mnFloatBits & ( WB_MOVEABLE | WB_SIZEABLE | WB_CLOSEABLE ) ) ) // no full drag when migrating to system window
266  mbDragFull = true;
267  else
268  {
269  StartDocking();
270  mbDragFull = false;
271  ImplUpdateAll();
273  }
274 
276 }
277 
279 {
280  mpWindowImpl->mbDockWin = true;
281  mpFloatWin = nullptr;
282  mpOldBorderWin = nullptr;
283  mpImplData.reset(new ImplData);
284  mnTrackX = 0;
285  mnTrackY = 0;
286  mnTrackWidth = 0;
287  mnTrackHeight = 0;
288  mnDockLeft = 0;
289  mnDockTop = 0;
290  mnDockRight = 0;
291  mnDockBottom = 0;
292  mnFloatBits = 0;
293  mbDockCanceled = false;
294  mbDockable = false;
295  mbDocking = false;
296  mbDragFull = false;
297  mbLastFloatMode = false;
298  mbStartFloat = false;
299  mbRollUp = false;
300  mbDockBtn = false;
301  mbHideBtn = false;
302  mbIsDeferredInit = false;
304  mpDialogParent = nullptr;
305 
306  //To-Do, reuse maResizeTimer
308  maLayoutIdle.SetInvokeHandler( LINK( this, DockingWindow, ImplHandleLayoutTimerHdl ) );
309  maLayoutIdle.SetDebugName( "vcl::DockingWindow maLayoutIdle" );
310 }
311 
313 {
314  if ( !(nStyle & WB_NODIALOGCONTROL) )
315  nStyle |= WB_DIALOGCONTROL;
316 
317  mpImplData->mpParent = pParent;
318  mbDockable = (nStyle & WB_DOCKABLE) != 0;
320  nStyle &= ~(DOCKWIN_FLOATSTYLES | WB_BORDER);
321 
322  Window::ImplInit( pParent, nStyle, nullptr );
323 
325 }
326 
328 {
329  // Hack: to be able to build DockingWindows w/o background before switching
330  // TODO: Hack
331  if ( !IsBackground() )
332  return;
333 
334  const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
335 
336  Color aColor;
337  if ( IsControlBackground() )
338  aColor = GetControlBackground();
339  else if ( Window::GetStyle() & WB_3DLOOK )
340  aColor = rStyleSettings.GetFaceColor();
341  else
342  aColor = rStyleSettings.GetWindowColor();
343  SetBackground( aColor );
344 }
345 
347  Window(nType)
348 {
350 }
351 
354 {
356  ImplInit( pParent, nStyle );
357 }
358 
359 //Find the real parent stashed in mpDialogParent.
361 {
362  vcl::Window *pParent = mpDialogParent;
363  mpDialogParent = nullptr;
364  ImplInit(pParent, nBits);
365  mbIsDeferredInit = false;
366 }
367 
368 void DockingWindow::loadUI(vcl::Window* pParent, const OString& rID, const OUString& rUIXMLDescription,
369  const css::uno::Reference<css::frame::XFrame> &rFrame)
370 {
371  mbIsDeferredInit = true;
372  mpDialogParent = pParent; //should be unset in doDeferredInit
373  m_pUIBuilder.reset( new VclBuilder(this, AllSettings::GetUIRootDir(), rUIXMLDescription, rID, rFrame) );
374 }
375 
376 DockingWindow::DockingWindow(vcl::Window* pParent, const OString& rID,
377  const OUString& rUIXMLDescription, const css::uno::Reference<css::frame::XFrame> &rFrame)
379 {
381 
382  loadUI(pParent, rID, rUIXMLDescription, rFrame);
383 }
384 
386 {
387  disposeOnce();
388 }
389 
391 {
392  if ( IsFloatingMode() )
393  {
394  Show( false, ShowFlags::NoFocusChange );
395  SetFloatingMode(false);
396  }
397  mpImplData.reset();
398  mpFloatWin.clear();
401  disposeBuilder();
402  Window::dispose();
403 }
404 
406 {
407  if( GetDockingManager()->IsDockable( this ) ) // new docking interface
408  return Window::Tracking( rTEvt );
409 
410  if ( !mbDocking )
411  return;
412 
413  if ( rTEvt.IsTrackingEnded() )
414  {
415  mbDocking = false;
416  if ( mbDragFull )
417  {
418  // reset old state on Cancel
419  if ( rTEvt.IsTrackingCanceled() )
420  {
421  StartDocking();
423  EndDocking( aRect, mbStartFloat );
424  }
425  }
426  else
427  {
428  HideTracking();
429  if ( rTEvt.IsTrackingCanceled() )
430  {
431  mbDockCanceled = true;
433  mbDockCanceled = false;
434  }
435  else
437  }
438  }
439  // dock only for non-synthetic MouseEvents
440  else if ( !rTEvt.GetMouseEvent().IsSynthetic() || rTEvt.GetMouseEvent().IsModifierChanged() )
441  {
442  Point aMousePos = rTEvt.GetMouseEvent().GetPosPixel();
443  Point aFrameMousePos = ImplOutputToFrame( aMousePos );
444  Size aFrameSize = mpWindowImpl->mpFrameWindow->GetOutputSizePixel();
445  if ( aFrameMousePos.X() < 0 )
446  aFrameMousePos.setX( 0 );
447  if ( aFrameMousePos.Y() < 0 )
448  aFrameMousePos.setY( 0 );
449  if ( aFrameMousePos.X() > aFrameSize.Width()-1 )
450  aFrameMousePos.setX( aFrameSize.Width()-1 );
451  if ( aFrameMousePos.Y() > aFrameSize.Height()-1 )
452  aFrameMousePos.setY( aFrameSize.Height()-1 );
453  aMousePos = ImplFrameToOutput( aFrameMousePos );
454  aMousePos.AdjustX( -(maMouseOff.X()) );
455  aMousePos.AdjustY( -(maMouseOff.Y()) );
456  Point aFramePos = ImplOutputToFrame( aMousePos );
457  tools::Rectangle aTrackRect( aFramePos, Size( mnTrackWidth, mnTrackHeight ) );
458  tools::Rectangle aCompRect = aTrackRect;
459  aFramePos.AdjustX(maMouseOff.X() );
460  aFramePos.AdjustY(maMouseOff.Y() );
461  if ( mbDragFull )
462  StartDocking();
463  bool bFloatMode = Docking( aFramePos, aTrackRect );
464  if ( mbLastFloatMode != bFloatMode )
465  {
466  if ( bFloatMode )
467  {
468  aTrackRect.AdjustLeft( -mnDockLeft );
469  aTrackRect.AdjustTop( -mnDockTop );
470  aTrackRect.AdjustRight(mnDockRight );
471  aTrackRect.AdjustBottom(mnDockBottom );
472  }
473  else
474  {
475  if ( aCompRect == aTrackRect )
476  {
477  aTrackRect.AdjustLeft(mnDockLeft );
478  aTrackRect.AdjustTop(mnDockTop );
479  aTrackRect.AdjustRight( -mnDockRight );
480  aTrackRect.AdjustBottom( -mnDockBottom );
481  }
482  }
483  mbLastFloatMode = bFloatMode;
484  }
485  if ( mbDragFull )
486  {
487  Point aOldPos = OutputToScreenPixel( Point() );
488  EndDocking( aTrackRect, mbLastFloatMode );
489  // repaint if state or position has changed
490  if ( aOldPos != OutputToScreenPixel( Point() ) )
491  {
492  ImplUpdateAll();
494  }
495 // EndDocking( aTrackRect, mbLastFloatMode );
496  }
497  else
498  {
499  ShowTrackFlags nTrackStyle;
500  if ( bFloatMode )
501  nTrackStyle = ShowTrackFlags::Big;
502  else
503  nTrackStyle = ShowTrackFlags::Object;
504  tools::Rectangle aShowTrackRect = aTrackRect;
505  aShowTrackRect.SetPos( ImplFrameToOutput( aShowTrackRect.TopLeft() ) );
506  ShowTracking( aShowTrackRect, nTrackStyle );
507 
508  // recalculate mouse offset, as the rectangle was changed
509  maMouseOff.setX( aFramePos.X() - aTrackRect.Left() );
510  maMouseOff.setY( aFramePos.Y() - aTrackRect.Top() );
511  }
512 
513  mnTrackX = aTrackRect.Left();
514  mnTrackY = aTrackRect.Top();
515  mnTrackWidth = aTrackRect.GetWidth();
516  mnTrackHeight = aTrackRect.GetHeight();
517  }
518 }
519 
521 {
522  if( GetDockingManager()->IsDockable( this ) ) // new docking interface
523  return Window::EventNotify( rNEvt );
524 
525  if ( mbDockable )
526  {
527  const bool bDockingSupportCrippled = !StyleSettings::GetDockingFloatsSupported();
528 
530  {
531  const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
532  if ( pMEvt->IsLeft() )
533  {
534  if (!bDockingSupportCrippled && pMEvt->IsMod1() && (pMEvt->GetClicks() == 2) )
535  {
537  if ( IsFloatingMode() )
539  return true;
540  }
541  else if ( pMEvt->GetClicks() == 1 )
542  {
543  // check if window is floating standalone (IsFloating())
544  // or only partially floating and still docked with one border
545  // ( !mpWindowImpl->mbFrame)
546  if( ! IsFloatingMode() || ! mpFloatWin->mpWindowImpl->mbFrame )
547  {
548  Point aPos = pMEvt->GetPosPixel();
549  vcl::Window* pWindow = rNEvt.GetWindow();
550  if ( pWindow != this )
551  {
552  aPos = pWindow->OutputToScreenPixel( aPos );
553  aPos = ScreenToOutputPixel( aPos );
554  }
555  ImplStartDocking( aPos );
556  }
557  return true;
558  }
559  }
560  }
561  else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
562  {
563  const vcl::KeyCode& rKey = rNEvt.GetKeyEvent()->GetKeyCode();
564  if( rKey.GetCode() == KEY_F10 && rKey.GetModifier() &&
565  rKey.IsShift() && rKey.IsMod1() && !bDockingSupportCrippled )
566  {
568  if ( IsFloatingMode() )
570  return true;
571  }
572  }
573  }
574 
575  return Window::EventNotify( rNEvt );
576 }
577 
579 {
580  mbDocking = true;
581 }
582 
584 {
585  return IsFloatingMode();
586 }
587 
588 void DockingWindow::EndDocking( const tools::Rectangle& rRect, bool bFloatMode )
589 {
590  bool bOrigDockCanceled = mbDockCanceled;
591  if (bFloatMode && !StyleSettings::GetDockingFloatsSupported())
592  mbDockCanceled = true;
593 
594  if ( !IsDockingCanceled() )
595  {
596  if ( bFloatMode != IsFloatingMode() )
597  {
598  SetFloatingMode( bFloatMode );
599  if ( IsFloatingMode() )
601  if ( bFloatMode && mpFloatWin )
602  mpFloatWin->SetPosSizePixel( rRect.TopLeft(), rRect.GetSize() );
603  }
604  if ( !bFloatMode )
605  {
606  Point aPos = rRect.TopLeft();
607  aPos = GetParent()->ScreenToOutputPixel( aPos );
608  Window::SetPosSizePixel( aPos, rRect.GetSize() );
609  }
610  }
611  mbDocking = false;
612  mbDockCanceled = bOrigDockCanceled;
613 }
614 
616 {
617  return true;
618 }
619 
621 {
622  VclPtr<vcl::Window> xWindow = this;
624  if ( xWindow->IsDisposed() )
625  return false;
626 
627  if ( mpWindowImpl->mxWindowPeer.is() && IsCreatedWithToolkit() )
628  return false;
629 
630  Show( false, ShowFlags::NoFocusChange );
631  return true;
632 }
633 
635 {
636 }
637 
639 {
640 }
641 
643 {
644  if (GetSettings().GetStyleSettings().GetAutoMnemonic())
645  Accelerator::GenerateAutoMnemonicsOnHierarchy(this);
646 
647  if (isLayoutEnabled())
648  {
651  if (IsFloatingMode())
654  }
655 }
656 
658 {
659  switch(nType)
660  {
662  DoInitialLayout();
663  break;
664 
667  Invalidate();
668  break;
669 
671  mbDockable = (GetStyle() & WB_DOCKABLE) != 0;
672  break;
673 
674  default:
675  break;
676  }
677 
678  Window::StateChanged( nType );
679 }
680 
682 {
683  if ( (rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
684  (rDCEvt.GetFlags() & AllSettingsFlags::STYLE) )
685  {
687  Invalidate();
688  }
689  else
690  Window::DataChanged( rDCEvt );
691 }
692 
693 void DockingWindow::SetFloatingMode( bool bFloatMode )
694 {
696  if( pWrapper )
697  {
698  pWrapper->SetFloatingMode( bFloatMode );
699  return;
700  }
701  if ( IsFloatingMode() == bFloatMode )
702  return;
703 
704  if ( !PrepareToggleFloatingMode() ) // changes to floating mode can be vetoed
705  return;
706 
707  bool bVisible = IsVisible();
708 
709  if ( bFloatMode )
710  {
711  // set deferred properties early, so border width will end up
712  // in our mpWindowImpl->mnBorderWidth, not in mpBorderWindow.
713  // (see its usage in setPosSizeOnContainee and GetOptimalSize.)
715 
716  Show( false, ShowFlags::NoFocusChange );
717 
718  maDockPos = Window::GetPosPixel();
719 
720  vcl::Window* pRealParent = mpWindowImpl->mpRealParent;
721  mpOldBorderWin = mpWindowImpl->mpBorderWindow;
722 
724  mpImplData->mpParent,
726  this );
727  mpFloatWin = pWin;
728  mpWindowImpl->mpBorderWindow = nullptr;
729  mpWindowImpl->mnLeftBorder = 0;
730  mpWindowImpl->mnTopBorder = 0;
731  mpWindowImpl->mnRightBorder = 0;
732  mpWindowImpl->mnBottomBorder = 0;
733  // if the parent gets destroyed, we also have to reset the parent of the BorderWindow
734  if ( mpOldBorderWin )
735  mpOldBorderWin->SetParent( pWin );
736 
737  // #i123765# reset the buffered DropTargets when undocking, else it may not
738  // be correctly initialized
739  mpWindowImpl->mxDNDListenerContainer.clear();
740 
741  SetParent( pWin );
742  SetPosPixel( Point() );
743  mpWindowImpl->mpBorderWindow = pWin;
744  pWin->mpWindowImpl->mpClientWindow = this;
745  mpWindowImpl->mpRealParent = pRealParent;
746  pWin->SetText( Window::GetText() );
747  Size aSize(Window::GetSizePixel());
748  pWin->SetOutputSizePixel(aSize);
749  pWin->SetPosPixel( maFloatPos );
750  // pass on DockingData to FloatingWindow
751  pWin->ShowTitleButton( TitleButton::Docking, mbDockBtn );
752  pWin->ShowTitleButton( TitleButton::Hide, mbHideBtn );
753  if ( mbRollUp )
754  pWin->RollUp();
755  else
756  pWin->RollDown();
757  pWin->SetRollUpOutputSizePixel( maRollUpOutSize );
758  pWin->SetMinOutputSizePixel( maMinOutSize );
759 
760  pWin->SetMaxOutputSizePixel( mpImplData->maMaxOutSize );
761 
763 
764  if ( bVisible )
765  Show();
766  }
767  else
768  {
769  Show( false, ShowFlags::NoFocusChange );
770 
771  // store FloatingData in FloatingWindow
778  mpImplData->maMaxOutSize = mpFloatWin->GetMaxOutputSizePixel();
779 
780  vcl::Window* pRealParent = mpWindowImpl->mpRealParent;
781  mpWindowImpl->mpBorderWindow = nullptr;
782  if ( mpOldBorderWin )
783  {
785  static_cast<ImplBorderWindow*>(mpOldBorderWin.get())->GetBorder( mpWindowImpl->mnLeftBorder, mpWindowImpl->mnTopBorder, mpWindowImpl->mnRightBorder, mpWindowImpl->mnBottomBorder );
787  }
788  mpWindowImpl->mpBorderWindow = mpOldBorderWin;
789  SetParent( pRealParent );
790  mpWindowImpl->mpRealParent = pRealParent;
793 
795 
796  if ( bVisible )
797  Show();
798  }
799 }
800 
802 {
804  if( pWrapper )
805  {
806  pWrapper->SetFloatStyle( nStyle );
807  return;
808  }
809 
810  mnFloatBits = nStyle;
811 }
812 
814 {
816  if( pWrapper )
817  {
818  return pWrapper->GetFloatStyle();
819  }
820 
821  return mnFloatBits;
822 }
823 
825  tools::Long nWidth, tools::Long nHeight,
826  PosSizeFlags nFlags )
827 {
829  if (pWrapper)
830  {
831  if (!pWrapper->mpFloatWin)
832  Window::setPosSizePixel( nX, nY, nWidth, nHeight, nFlags );
833  }
834  else
835  {
836  if (!mpFloatWin)
837  Window::setPosSizePixel( nX, nY, nWidth, nHeight, nFlags );
838  else
839  {
840  mpFloatWin->SetOutputSizePixel(Size(nWidth, nHeight));
841  mpFloatWin->SetPosPixel(Point(nX, nY));
842  }
843  }
844 
845  if (::isLayoutEnabled(this))
847 }
848 
850 {
852  if( pWrapper )
853  {
854  if ( pWrapper->mpFloatWin )
855  return pWrapper->mpFloatWin->GetPosPixel();
856  else
857  return Window::GetPosPixel();
858  }
859 
860  if ( mpFloatWin )
861  return mpFloatWin->GetPosPixel();
862  else
863  return Window::GetPosPixel();
864 }
865 
867 {
869  if( pWrapper )
870  {
871  if ( pWrapper->mpFloatWin )
872  return pWrapper->mpFloatWin->GetSizePixel();
873  else
874  return Window::GetSizePixel();
875  }
876 
877  if ( mpFloatWin )
878  return mpFloatWin->GetSizePixel();
879  else
880  return Window::GetSizePixel();
881 }
882 
884 {
886  if( pWrapper )
887  {
888  if ( pWrapper->mpFloatWin )
889  pWrapper->mpFloatWin->SetOutputSizePixel( rNewSize );
890  else
891  Window::SetOutputSizePixel( rNewSize );
892  return;
893  }
894 
895  if ( mpFloatWin )
896  mpFloatWin->SetOutputSizePixel( rNewSize );
897  else
898  Window::SetOutputSizePixel( rNewSize );
899 }
900 
902 {
904  if( pWrapper )
905  {
906  if ( pWrapper->mpFloatWin )
907  return pWrapper->mpFloatWin->GetOutputSizePixel();
908  else
909  return Window::GetOutputSizePixel();
910  }
911 
912  if ( mpFloatWin )
913  return mpFloatWin->GetOutputSizePixel();
914  else
915  return Window::GetOutputSizePixel();
916 }
917 
919 {
921  if( pWrapper )
922  {
923  if ( pWrapper->mpFloatWin )
924  {
926  aData.SetMask( WindowStateMask::Pos );
927  pWrapper->mpFloatWin->GetWindowStateData( aData );
928  Point aPos( aData.GetX(), aData.GetY() );
929  aPos = pWrapper->mpFloatWin->GetParent()->ImplGetFrameWindow()->AbsoluteScreenToOutputPixel( aPos );
930  return aPos;
931  }
932  else
933  return maFloatPos;
934  }
935 
936  if ( mpFloatWin )
937  {
939  aData.SetMask( WindowStateMask::Pos );
940  mpFloatWin->GetWindowStateData( aData );
941  Point aPos( aData.GetX(), aData.GetY() );
943  return aPos;
944  }
945  else
946  return maFloatPos;
947 }
948 
950 {
952  if( pWrapper )
953  return pWrapper->IsFloatingMode();
954  else
955  return (mpFloatWin != nullptr);
956 }
957 
959 {
960  if ( mpFloatWin )
962  mpImplData->maMaxOutSize = rSize;
963 }
964 
965 void DockingWindow::SetText(const OUString& rStr)
966 {
968  Window::SetText(rStr);
969 }
970 
971 OUString DockingWindow::GetText() const
972 {
973  const_cast<DockingWindow*>(this)->setDeferredProperties();
974  return Window::GetText();
975 }
976 
978 {
979  //pre dtor called, and single child is a container => we're layout enabled
980  return mpImplData && ::isLayoutEnabled(this);
981 }
982 
984 {
985  maLayoutIdle.Stop();
986 
987  //resize DockingWindow to fit requisition on initial show
988  Size aSize = get_preferred_size();
989 
991 
992  aSize.setWidth( std::min(aMax.Width(), aSize.Width()) );
993  aSize.setHeight( std::min(aMax.Height(), aSize.Height()) );
994 
995  SetMinOutputSizePixel(aSize);
997 }
998 
1000 {
1001  Size aSize = GetOutputSizePixel();
1002 
1003  // Don't make the border width accessible via get_border_width(),
1004  // otherwise the floating window will handle the border as well.
1005  sal_Int32 nBorderWidth = mpWindowImpl->mnBorderWidth;
1006 
1007  aSize.AdjustWidth( -(2 * nBorderWidth) );
1008  aSize.AdjustHeight( -(2 * nBorderWidth) );
1009 
1011  assert(pBox);
1012  VclContainer::setLayoutAllocation(*pBox, Point(nBorderWidth, nBorderWidth), aSize);
1013 }
1014 
1016 {
1017  if (!isLayoutEnabled())
1018  return Window::GetOptimalSize();
1019 
1021 
1022  // Don't make the border width accessible via get_border_width(),
1023  // otherwise the floating window will handle the border as well.
1024  sal_Int32 nBorderWidth = mpWindowImpl->mnBorderWidth;
1025 
1026  aSize.AdjustHeight(2 * nBorderWidth );
1027  aSize.AdjustWidth(2 * nBorderWidth );
1028 
1029  return aSize;
1030 }
1031 
1033 {
1034  bool bTriggerLayout = true;
1036  {
1037  bTriggerLayout = false;
1038  }
1039  if (!isLayoutEnabled())
1040  {
1041  bTriggerLayout = false;
1042  }
1043  if (bTriggerLayout)
1044  {
1046  maLayoutIdle.Start();
1047  }
1048  vcl::Window::queue_resize(eReason);
1049 }
1050 
1051 IMPL_LINK_NOARG(DockingWindow, ImplHandleLayoutTimerHdl, Timer*, void)
1052 {
1053  if (!isLayoutEnabled())
1054  {
1055  SAL_WARN_IF(GetWindow(GetWindowType::FirstChild), "vcl.layout", "DockingWindow has become non-layout because extra children have been added directly to it.");
1056  return;
1057  }
1058  setPosSizeOnContainee();
1059 }
1060 
1061 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual Point GetPosPixel() const
Definition: window.cxx:2789
Point TopLeft() const
void setOptimalLayoutSize()
Definition: dockwin.cxx:983
void SetOutputSizePixel(const Size &rNewSize) override
Definition: dockwin.cxx:883
void SetPos(const Point &rPoint)
bool IsControlBackground() const
Definition: window2.cxx:1087
bool IsInputEnabled() const
Definition: window2.cxx:1127
virtual void Move()
Definition: window.cxx:1832
WinBits const WB_DOCKABLE
bool mbLastFloatMode
Definition: dockwin.hxx:236
void setDeferredProperties()
Definition: builder.hxx:479
ActivateModeFlags GetActivateMode() const
Definition: window2.cxx:1137
static void setLayoutAllocation(vcl::Window &rWindow, const Point &rPos, const Size &rSize)
Definition: layout.cxx:67
virtual void SetText(const OUString &rStr) override
Definition: dockwin.cxx:965
bool mbDocking
Definition: dockwin.hxx:236
SAL_DLLPRIVATE void DoInitialLayout()
Definition: dockwin.cxx:642
bool bVisible
WinBits const WB_SYSTEMWINDOW
constexpr sal_uInt16 KEY_MOD1
Definition: keycodes.hxx:31
Idle maLayoutIdle
Definition: dockwin.hxx:235
virtual bool PrepareToggleFloatingMode()
Definition: dockwin.cxx:615
virtual void Tracking(const TrackingEvent &rTEvt) override
Definition: dockwin.cxx:405
tools::Long AdjustRight(tools::Long nHorzMoveDelta)
void setWidth(tools::Long nWidth)
bool IsDockable() const
Definition: dockwin.hxx:311
const char aData[]
SAL_DLLPRIVATE void setPosSizeOnContainee()
Definition: dockwin.cxx:999
bool IsRollUp() const
Definition: syswin.hxx:146
WinBits const WB_NODIALOGCONTROL
bool IsBackground() const
Definition: outdev.hxx:645
Resize runs before repaint, so we won't paint twice.
SAL_DLLPRIVATE Point ImplOutputToFrame(const Point &rPos)
Definition: window2.cxx:937
Point AbsoluteScreenToOutputPixel(const Point &rPos) const
Definition: window.cxx:2860
int GetY() const
Definition: windowstate.hxx:62
sal_Int32 mnDockRight
Definition: dockwin.hxx:232
static Size getLayoutRequisition(const vcl::Window &rWindow)
Definition: layout.cxx:142
long Long
void disposeAndClear()
Definition: vclptr.hxx:200
const StyleSettings & GetStyleSettings() const
bool mbIsDeferredInit
Definition: dockwin.hxx:248
Point maDockPos
Definition: dockwin.hxx:222
const Color & GetFaceColor() const
bool mbDockBtn
Definition: dockwin.hxx:236
Important idle events to be run before processing drawing events.
void InvalidateSizeCache()
clear OptimalSize cache
Definition: window2.cxx:1307
void HideTracking()
Definition: window2.cxx:147
int GetX() const
Definition: windowstate.hxx:60
virtual Size GetSizePixel() const
Definition: window.cxx:2400
SAL_DLLPRIVATE vcl::Window * ImplGetFrameWindow() const
Definition: window2.cxx:901
const Size & GetMaxOutputSizePixel() const
Definition: syswin.cxx:429
static ImplSVEvent * PostUserEvent(const Link< void *, void > &rLink, void *pCaller=nullptr, bool bReferenceLink=false)
Post a user event to the default window.
Definition: svapp.cxx:999
sal_uInt16 GetCode() const
Definition: keycod.hxx:51
tools::Long GetWidth() const
PosSizeFlags
Definition: window.hxx:140
DataChangedEventType GetType() const
Definition: event.hxx:356
const KeyEvent * GetKeyEvent() const
Definition: event.hxx:310
#define DOCKWIN_FLOATSTYLES
Definition: dockwin.cxx:36
Point maMouseOff
Definition: dockwin.hxx:223
tools::Rectangle GetDesktopRectPixel() const
Definition: window.cxx:2794
virtual void Resizing(Size &rSize)
Definition: syswin.cxx:295
virtual void SetSettings(const AllSettings &rSettings) override
const Color & GetControlBackground() const
Definition: window2.cxx:1082
bool IsCreatedWithToolkit() const
Definition: window2.cxx:1237
SAL_DLLPRIVATE void ImplUpdateAll()
Definition: paint.cxx:989
bool IsDockingCanceled() const
Definition: dockwin.hxx:312
Point GetPosPixel() const override
Definition: dockwin.cxx:849
void StartTracking(StartTrackingFlags nFlags=StartTrackingFlags::NONE)
Definition: window2.cxx:244
bool IsFloatingMode() const
Definition: dockmgr.cxx:1039
DockingWindow(const DockingWindow &)=delete
void ImplStartDocking(const Point &rPos)
Definition: dockwin.cxx:227
bool IsActive() const
Definition: task.hxx:90
StateChangedType
Definition: window.hxx:317
sal_uInt16 GetClicks() const
Definition: event.hxx:123
sal_Int64 WinBits
vcl::Window * GetWindow() const
Definition: event.hxx:303
void SetBackground()
IMPL_LINK_NOARG(ImplDockFloatWin, DockTimerHdl, Timer *, void)
Definition: dockwin.cxx:124
void Enable(bool bEnable=true, bool bChild=true)
Definition: window.cxx:2431
tools::Long Left() const
virtual Size GetOptimalSize() const override
Definition: dockwin.cxx:1015
Creates a hierarchy of vcl::Windows (widgets) from a .ui file for dialogs, sidebar, etc.
Definition: builder.hxx:65
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
void EnableAlwaysOnTop(bool bEnable=true)
Definition: stacking.cxx:598
void ShowTracking(const tools::Rectangle &rRect, ShowTrackFlags nFlags=ShowTrackFlags::Small)
Definition: window2.cxx:124
virtual void StartDocking()
Definition: dockwin.cxx:578
virtual void setPosSizePixel(tools::Long nX, tools::Long nY, tools::Long nWidth, tools::Long nHeight, PosSizeFlags nFlags=PosSizeFlags::All) override
Definition: dockwin.cxx:824
AllSettingsFlags GetFlags() const
Definition: event.hxx:357
virtual void Start() override
Activates the timer task.
Definition: idle.cxx:34
void loadUI(vcl::Window *pParent, const OString &rID, const OUString &rUIXMLDescription, const css::uno::Reference< css::frame::XFrame > &rFrame)
Definition: dockwin.cxx:368
void SetFloatStyle(WinBits nWinStyle)
Definition: dockwin.cxx:801
virtual void queue_resize(StateChangedType eReason=StateChangedType::Layout)
Definition: window2.cxx:1327
bool mbHideBtn
Definition: dockwin.hxx:236
virtual void SetOutputSizePixel(const Size &rNewSize)
Definition: window2.cxx:1274
sal_uInt16 GetModifier() const
Definition: keycod.hxx:54
virtual void queue_resize(StateChangedType eReason=StateChangedType::Layout) override
Definition: dockwin.cxx:1032
WinBits mnFloatBits
Definition: dockwin.hxx:234
tools::Long AdjustBottom(tools::Long nVertMoveDelta)
virtual bool Docking(const Point &rPos, tools::Rectangle &rRect)
Definition: dockwin.cxx:583
Size GetOutputSizePixel() const
Definition: dockwin.cxx:901
#define MOUSE_LEFT
Definition: event.hxx:99
const Size & GetMinOutputSizePixel() const
Definition: syswin.hxx:152
virtual void EndDocking(const tools::Rectangle &rRect, bool bFloatMode)
Definition: dockwin.cxx:588
void SetDebugName(const char *pDebugName)
Definition: task.hxx:81
bool isLayoutEnabled() const
Definition: dockwin.cxx:977
bool IsAlwaysOnTopEnabled() const
Definition: window2.cxx:1143
sal_Int32 mnDockBottom
Definition: dockwin.hxx:233
static void RemoveUserEvent(ImplSVEvent *nUserEvent)
Remove user event based on event ID.
Definition: svapp.cxx:1027
void EnableInput(bool bEnable=true, bool bChild=true)
Definition: window.cxx:2491
static OUString GetUIRootDir()
Definition: dialog.cxx:547
WinBits const WB_DIALOGCONTROL
void clear()
Definition: vclptr.hxx:190
virtual void dispose() override
This is intended to be used to clear any locally held references to other Window-subclass objects...
Definition: dockwin.cxx:390
tools::Long mnTrackX
Definition: dockwin.hxx:226
bool mbIsCalculatingInitialLayoutSize
Definition: dockwin.hxx:236
void SetActivateMode(ActivateModeFlags nMode)
Definition: window.cxx:2633
VclPtr< vcl::Window > mpParent
Definition: dockwin.cxx:43
Window(WindowType nType)
Definition: window.cxx:91
Point maFloatPos
Definition: dockwin.hxx:221
bool IsFloatingMode() const
Definition: dockwin.cxx:949
virtual ~DockingWindow() override
Definition: dockwin.cxx:385
void ToTop(ToTopFlags nFlags=ToTopFlags::NONE)
Definition: stacking.cxx:420
void SetMaxOutputSizePixel(const Size &rSize)
Definition: syswin.cxx:410
WinBits GetFloatStyle() const
Definition: dockwin.hxx:161
const Size & GetRollUpOutputSizePixel() const
Definition: syswin.hxx:149
ImplDockingWindowWrapper.
Definition: dockwin.hxx:70
void SetParent(vcl::Window *pNewParent)
Definition: stacking.cxx:835
virtual void Invalidate(InvalidateFlags nFlags=InvalidateFlags::NONE)
Definition: paint.cxx:1164
ShowTrackFlags
Definition: window.hxx:275
VclPtr< FloatingWindow > mpFloatWin
Definition: dockwin.hxx:82
tools::Long Width() const
bool mbDockable
Definition: dockwin.hxx:236
std::unique_ptr< WindowImpl > mpWindowImpl
Definition: window.hxx:519
void SetFloatingMode(bool bFloatMode)
Definition: dockwin.cxx:693
virtual void Resize()
Definition: window.cxx:1834
Size get_preferred_size() const
Definition: window2.cxx:1653
std::unique_ptr< VclBuilder > m_pUIBuilder
Definition: builder.hxx:487
bool isLayoutEnabled(const vcl::Window *pWindow)
Definition: layout.cxx:2878
MouseNotifyEvent GetType() const
Definition: event.hxx:302
const AllSettings & GetSettings() const
Definition: outdev.hxx:417
Size GetOutputSizePixel() const
Definition: outdev.hxx:440
SAL_DLLPRIVATE void ImplInitDockingWindowData()
Definition: dockwin.cxx:278
tools::Long Top() const
Point ScreenToOutputPixel(const Point &rPos) const
Definition: window.cxx:2807
Size maMinOutSize
Definition: dockwin.hxx:225
bool IsTitleButtonVisible(TitleButton nButton) const
Definition: syswin.cxx:361
constexpr sal_uInt16 KEY_F10
Definition: keycodes.hxx:92
vcl::Window * GetParent() const
Definition: window2.cxx:1097
bool IsTrackingEnded() const
Definition: event.hxx:263
Point OutputToAbsoluteScreenPixel(const Point &rPos) const
Definition: window.cxx:2850
virtual void StateChanged(StateChangedType nType) override
Definition: dockwin.cxx:657
Size GetSize() const
virtual void SetPosSizePixel(const Point &rNewPos, const Size &rNewSize)
Definition: window2.cxx:1268
void SetFloatingMode(bool bFloatMode)
Definition: dockmgr.cxx:877
tools::Long AdjustTop(tools::Long nVertMoveDelta)
vcl::Window * GetWindow(GetWindowType nType) const
Definition: stacking.cxx:1039
void disposeBuilder()
Definition: dialog.cxx:541
virtual bool EventNotify(NotifyEvent &rNEvt) override
Definition: dockwin.cxx:520
void SetMask(WindowStateMask nValidMask)
Definition: windowstate.hxx:56
tools::Long mnTrackWidth
Definition: dockwin.hxx:228
VclPtr< vcl::Window > mpOldBorderWin
Definition: dockwin.hxx:219
WinBits const WB_3DLOOK
WinBits const WB_SIZEABLE
bool IsModifierChanged() const
Definition: event.hxx:141
void GetBorder(sal_Int32 &rLeftBorder, sal_Int32 &rTopBorder, sal_Int32 &rRightBorder, sal_Int32 &rBottomBorder) const
Definition: window.cxx:2422
void GetWindowStateData(WindowStateData &rData) const
Definition: syswin.cxx:799
A construction helper for a temporary VclPtr.
Definition: vclptr.hxx:275
Size GetSizePixel() const override
Definition: dockwin.cxx:866
const vcl::KeyCode & GetKeyCode() const
Definition: event.hxx:54
bool IsShift() const
Definition: keycod.hxx:56
tools::Long mnTrackY
Definition: dockwin.hxx:227
Point GetFloatingPos() const
Definition: dockwin.cxx:918
SAL_DLLPRIVATE void ImplInitSettings()
Definition: dockwin.cxx:327
void AlwaysEnableInput(bool bAlways, bool bChild=true)
Override EnableInput.
Definition: window.cxx:2606
void Stop()
Definition: scheduler.cxx:601
DockingManager * ImplGetDockingManager()
Definition: svdata.cxx:308
WindowType
static bool GetDockingFloatsSupported()
bool IsSynthetic() const
Definition: event.hxx:139
#define SAL_WARN_IF(condition, area, stream)
WinBits const WB_BORDER
const MouseEvent * GetMouseEvent() const
Definition: event.hxx:318
void SetMaxOutputSizePixel(const Size &rSize)
Definition: dockwin.cxx:958
bool IsVisible() const
Definition: window2.cxx:1102
tools::Long mnTrackHeight
Definition: dockwin.hxx:229
virtual void doDeferredInit(WinBits nBits)
Definition: dockwin.cxx:360
ImplDockingWindowWrapper * GetDockingWindowWrapper(const vcl::Window *pWin)
Definition: dockmgr.cxx:278
bool IsLeft() const
Definition: event.hxx:146
tools::Long AdjustWidth(tools::Long n)
bool IsMod1() const
Definition: keycod.hxx:58
static VclPtr< reference_type > Create(Arg &&...arg)
A construction helper for VclPtr.
Definition: vclptr.hxx:127
sal_Int32 mnDockTop
Definition: dockwin.hxx:231
SAL_DLLPRIVATE Point ImplFrameToOutput(const Point &rPos)
Definition: window2.cxx:942
tools::Long Height() const
void SetInvokeHandler(const Link< Timer *, void > &rLink)
Definition: timer.hxx:56
const Color & GetWindowColor() const
const Point & GetPosPixel() const
Definition: event.hxx:120
static sal_uInt64 GetSystemTicks()
tools::Long AdjustHeight(tools::Long n)
std::unique_ptr< ImplData > mpImplData
Definition: dockwin.hxx:220
bool IsDisposed() const
Definition: window.cxx:142
void setHeight(tools::Long nHeight)
tools::Long GetHeight() const
bool mbStartFloat
Definition: dockwin.hxx:236
bool IsAlwaysEnableInput() const
returns the current AlwaysEnableInput state
Definition: window2.cxx:1132
virtual OUString GetText() const override
Definition: dockwin.cxx:971
reference_type * get() const
Get the body.
Definition: vclptr.hxx:143
bool IsEnabled() const
Definition: window2.cxx:1122
tools::Long AdjustLeft(tools::Long nHorzMoveDelta)
virtual bool Close()
Definition: dockwin.cxx:620
sal_Int32 mnDockLeft
Definition: dockwin.hxx:230
bool IsTrackingCanceled() const
Definition: event.hxx:265
WinBits GetStyle() const
Definition: window2.cxx:953
Definition: timer.hxx:26
void SetPriority(TaskPriority ePriority)
Definition: scheduler.cxx:608
Point OutputToScreenPixel(const Point &rPos) const
Definition: window.cxx:2801
#define MOUSE_MIDDLE
Definition: event.hxx:100
WinBits const WB_CLOSEABLE
WinBits const WB_MOVEABLE
Size maRollUpOutSize
Definition: dockwin.hxx:224
VclPtr< FloatingWindow > mpFloatWin
Definition: dockwin.hxx:218
void CallEventListeners(VclEventId nEvent, void *pData=nullptr)
Definition: event.cxx:217
virtual void DataChanged(const DataChangedEvent &rDCEvt) override
Definition: dockwin.cxx:681
const MouseEvent & GetMouseEvent() const
Definition: event.hxx:259
SAL_DLLPRIVATE void ImplInit(vcl::Window *pParent, WinBits nStyle)
Definition: dockwin.cxx:312
virtual void Resizing(Size &rSize)
Definition: dockwin.cxx:638
virtual void dispose() override
This is intended to be used to clear any locally held references to other Window-subclass objects...
Definition: floatwin.cxx:204
PointerState GetPointerState()
Definition: mouse.cxx:587
WinBits GetFloatStyle() const
Definition: dockwin.cxx:813
void SetMinOutputSizePixel(const Size &rSize)
Definition: dockwin.hxx:355
#define MOUSE_RIGHT
Definition: event.hxx:101
virtual void SetPosPixel(const Point &rNewPos)
Definition: window2.cxx:1257
virtual void Resize() override
Definition: syswin.cxx:1053
virtual void ToggleFloatingMode()
Definition: dockwin.cxx:634
bool mbDockCanceled
Definition: dockwin.hxx:236
VclPtr< vcl::Window > mpDialogParent
Definition: dockwin.hxx:249
bool mbDragFull
Definition: dockwin.hxx:236
An idle is a timer to be scheduled immediately.
Definition: idle.hxx:30
static DockingManager * GetDockingManager()
Definition: window2.cxx:803
void SetFloatStyle(WinBits nWinStyle)
Definition: dockmgr.cxx:991
Size bestmaxFrameSizeForScreenSize(const Size &rScreenSize)
Definition: dialog.cxx:693
bool IsMod1() const
Definition: event.hxx:157
void Show(bool bVisible=true, ShowFlags nFlags=ShowFlags::NONE)
Definition: window.cxx:2186