MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / floatPanel

Method floatPanel

Gui/DockablePanel.cpp:1258–1293  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1256}
1257
1258FloatingWidget*
1259DockablePanel::floatPanel()
1260{
1261 _imp->_floating = !_imp->_floating;
1262 {
1263 QMutexLocker k(&_imp->_isClosedMutex);
1264 _imp->_isClosed = false;
1265 }
1266 if (_imp->_floating) {
1267 assert(!_imp->_floatingWidget);
1268
1269 QSize curSize = sizeHint();
1270
1271
1272 _imp->_floatingWidget = new FloatingWidget(_imp->_gui, _imp->_gui);
1273 QObject::connect( _imp->_floatingWidget, SIGNAL(closed()), this, SLOT(closePanel()) );
1274 _imp->_container->removeWidget(this);
1275 _imp->_floatingWidget->setWidget(this);
1276 _imp->_floatingWidget->resize(curSize);
1277 _imp->_gui->registerFloatingWindow(_imp->_floatingWidget);
1278 } else {
1279 assert(_imp->_floatingWidget);
1280 _imp->_gui->unregisterFloatingWindow(_imp->_floatingWidget);
1281 _imp->_floatingWidget->removeEmbeddedWidget();
1282 //setParent( _imp->_container->parentWidget() );
1283 //_imp->_container->insertWidget(0, this);
1284 _imp->_gui->addVisibleDockablePanel(this);
1285 _imp->_floatingWidget->deleteLater();
1286 _imp->_floatingWidget = 0;
1287 }
1288 Gui* gui = getGui();
1289 if (gui) {
1290 gui->buildTabFocusOrderPropertiesBin();
1291 }
1292 return _imp->_floatingWidget;
1293}
1294
1295void
1296DockablePanel::setName(const QString & str)

Callers 2

showNodePanelMethod · 0.80
restoreLayoutMethod · 0.80

Calls 9

sizeHintFunction · 0.85
getGuiFunction · 0.85
setWidgetMethod · 0.80
removeEmbeddedWidgetMethod · 0.80
resizeMethod · 0.45

Tested by

no test coverage detected