Changeset View
Changeset View
Standalone View
Standalone View
src/SpectacleCore.cpp
Show First 20 Lines • Show All 271 Lines • ▼ Show 20 Line(s) | 265 | { | |||
---|---|---|---|---|---|
272 | } else { | 272 | } else { | ||
273 | QUrl lSavePath = (mStartMode == StartMode::Background && mFileNameUrl.isValid() && mFileNameUrl.isLocalFile()) ? | 273 | QUrl lSavePath = (mStartMode == StartMode::Background && mFileNameUrl.isValid() && mFileNameUrl.isLocalFile()) ? | ||
274 | mFileNameUrl : QUrl(); | 274 | mFileNameUrl : QUrl(); | ||
275 | lExportManager->doSave(lSavePath); | 275 | lExportManager->doSave(lSavePath); | ||
276 | } | 276 | } | ||
277 | 277 | | |||
278 | // if we notify, we emit allDone only if the user either dismissed the notification or pressed | 278 | // if we notify, we emit allDone only if the user either dismissed the notification or pressed | ||
279 | // the "Open" button, otherwise the app closes before it can react to it. | 279 | // the "Open" button, otherwise the app closes before it can react to it. | ||
280 | if (!mNotify) { | 280 | if (!mNotify && mCopyToClipboard) { | ||
281 | // Allow some time for clipboard content to transfer if '--nonotify' is used, see Bug #411263 | ||||
282 | // TODO: Find better solution | ||||
283 | QTimer::singleShot(250, this, &SpectacleCore::allDone); | ||||
284 | } else if (!mNotify) { | ||||
281 | emit allDone(); | 285 | emit allDone(); | ||
282 | } | 286 | } | ||
283 | } | 287 | } | ||
284 | break; | 288 | break; | ||
285 | case StartMode::Gui: | 289 | case StartMode::Gui: | ||
286 | mMainWindow->setScreenshotAndShow(thePixmap); | 290 | mMainWindow->setScreenshotAndShow(thePixmap); | ||
287 | 291 | | |||
288 | bool autoSaveImage = SpectacleConfig::instance()->autoSaveImage(); | 292 | bool autoSaveImage = SpectacleConfig::instance()->autoSaveImage(); | ||
▲ Show 20 Lines • Show All 157 Lines • Show Last 20 Lines |