MCPcopy Create free account
hub / github.com/Codeya-IDE/deepin-ide / resizeDock

Method resizeDock

src/plugins/core/uicontroller/mainwindow.cpp:232–250  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

230}
231
232void MainWindow::resizeDock(QDockWidget *dock)
233{
234 auto area = dockWidgetArea(dock);
235
236 QSize size(300, 300);
237 foreach (auto name, d->dockList.keys()) {
238 if (dockWidgetArea(d->dockList[name]) == area) {
239 size = d->dockList[name]->size();
240 break;
241 }
242 }
243
244 //(100, 30) means dockWidget havn`t init
245 if (size == QSize(100, 30))
246 size = QSize(300, 300);
247
248 resizeDocks({ dock }, { size.width() }, Qt::Horizontal);
249 resizeDocks({ dock }, { size.height() }, Qt::Vertical);
250}
251
252void MainWindow::resizeDock(const QString &dockName, QSize size)
253{

Callers 3

showRightspaceMethod · 0.80
initContextWidgetMethod · 0.80
showWorkspaceMethod · 0.80

Calls 2

widthMethod · 0.80
containsMethod · 0.45

Tested by

no test coverage detected