Skip to content

Replace dialog boxes with in-app notifications for missing screenshots #41

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 0 additions & 34 deletions electron/ProcessingHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,15 +201,6 @@ export class ProcessingHelper {
if (!screenshotQueue || screenshotQueue.length === 0) {
console.log("No screenshots found in queue");
mainWindow.webContents.send(this.deps.PROCESSING_EVENTS.NO_SCREENSHOTS);

// Show dialog if no screenshots
dialog.showMessageBox(mainWindow, {
type: 'info',
title: 'No Screenshots Detected',
message: 'No screenshots were found to process.',
detail: 'Please take a screenshot first using Ctrl+H (or Cmd+H on Mac). Make sure your screenshot contains the coding problem you want to solve.',
buttons: ['OK']
});
return;
}

Expand All @@ -218,15 +209,6 @@ export class ProcessingHelper {
if (existingScreenshots.length === 0) {
console.log("Screenshot files don't exist on disk");
mainWindow.webContents.send(this.deps.PROCESSING_EVENTS.NO_SCREENSHOTS);

// Show error dialog
dialog.showMessageBox(mainWindow, {
type: 'warning',
title: 'Screenshot Files Missing',
message: 'The screenshot files were not found on disk.',
detail: 'Try taking a new screenshot with Ctrl+H (or Cmd+H on Mac).',
buttons: ['OK']
});
return;
}

Expand Down Expand Up @@ -318,14 +300,6 @@ export class ProcessingHelper {
console.log("No extra screenshots found in queue");
mainWindow.webContents.send(this.deps.PROCESSING_EVENTS.NO_SCREENSHOTS);

// Show dialog if no screenshots
dialog.showMessageBox(mainWindow, {
type: 'info',
title: 'No Debug Screenshots',
message: 'No screenshots were found for debugging.',
detail: 'Please take screenshots of your code/errors with Ctrl+H before debugging.',
buttons: ['OK']
});
return;
}

Expand All @@ -334,14 +308,6 @@ export class ProcessingHelper {
if (existingExtraScreenshots.length === 0) {
console.log("Extra screenshot files don't exist on disk");
mainWindow.webContents.send(this.deps.PROCESSING_EVENTS.NO_SCREENSHOTS);

dialog.showMessageBox(mainWindow, {
type: 'warning',
title: 'Screenshot Files Missing',
message: 'The debug screenshot files were not found.',
detail: 'Try taking a new screenshot with Ctrl+H (or Cmd+H on Mac).',
buttons: ['OK']
});
return;
}

Expand Down