Implement single method capture request
The core now has a method requestCapture, which receives a CaptureRequest object with all the needed information. This reduces code duplication in future features.
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
|
||||
#include "screengrabber.h"
|
||||
#include "src/utils/filenamehandler.h"
|
||||
#include "src/utils/systemnotification.h"
|
||||
#include <QPixmap>
|
||||
#include <QScreen>
|
||||
#include <QGuiApplication>
|
||||
@@ -65,6 +66,9 @@ QPixmap ScreenGrabber::grabEntireDesktop(bool &ok) {
|
||||
ok = false;
|
||||
break;
|
||||
}
|
||||
if (!ok) {
|
||||
SystemNotification().sendMessage(tr("Unable to capture screen"));
|
||||
}
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user