mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-24 11:54:01 +00:00
Added the "use File -> new after adding a job" option
This commit is contained in:
parent
0802fbba33
commit
53779c6e8c
@ -1,3 +1,8 @@
|
||||
2004-06-25 Moritz Bunkus <moritz@bunkus.org>
|
||||
|
||||
* mmg: new feature: Added an option for automatically calling
|
||||
'File -> new' after a job has been added to the job queue.
|
||||
|
||||
2004-06-24 Moritz Bunkus <moritz@bunkus.org>
|
||||
|
||||
* mkvextract: bug fix: Video extraction was not working correctly
|
||||
|
@ -551,15 +551,8 @@ create_track_order() {
|
||||
}
|
||||
|
||||
void
|
||||
wxdie(const wxString &errmsg,
|
||||
...) {
|
||||
wxString buffer;
|
||||
va_list ap;
|
||||
|
||||
va_start(ap, errmsg);
|
||||
buffer.PrintfV(errmsg, ap);
|
||||
va_end(ap);
|
||||
wxMessageBox(buffer, wxT("A serious error occured"), wxOK | wxICON_ERROR);
|
||||
wxdie(const wxString &errmsg) {
|
||||
wxMessageBox(errmsg, wxT("A serious error occured"), wxOK | wxICON_ERROR);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
@ -1591,6 +1584,11 @@ mmg_dialog::on_add_to_jobqueue(wxCommandEvent &evt) {
|
||||
|
||||
save_job_queue();
|
||||
|
||||
if (settings_page->cb_filenew_after_add_to_jobqueue->IsChecked()) {
|
||||
wxCommandEvent dummy;
|
||||
on_file_new(dummy);
|
||||
}
|
||||
|
||||
set_status_bar(wxT("Job added to job queue"));
|
||||
}
|
||||
|
||||
|
@ -112,7 +112,7 @@ void set_on_top(bool on_top);
|
||||
void restore_on_top();
|
||||
wxString create_track_order();
|
||||
|
||||
void wxdie(const wxString &errmsg, ...);
|
||||
void wxdie(const wxString &errmsg);
|
||||
|
||||
#if defined(SYS_WINDOWS)
|
||||
#define TIP(s) format_tooltip(wxT(s))
|
||||
|
@ -100,6 +100,13 @@ tab_settings::tab_settings(wxWindow *parent):
|
||||
"whose description matches the "
|
||||
"new one."));
|
||||
siz_misc->Add(cb_ask_before_overwriting, 0, wxLEFT, 5);
|
||||
|
||||
siz_misc->Add(0, 5, 0, 0, 0);
|
||||
cb_filenew_after_add_to_jobqueue =
|
||||
new wxCheckBox(this, ID_CB_NEW_AFTER_ADD_TO_JOBQUEUE,
|
||||
wxT("Clear inputs after adding a job to the job queue"));
|
||||
siz_misc->Add(cb_filenew_after_add_to_jobqueue,0, wxLEFT, 5);
|
||||
|
||||
cb_on_top = new wxCheckBox(this, ID_CB_ON_TOP, wxT("Always on top"));
|
||||
#if defined(SYS_WINDOWS)
|
||||
siz_misc->Add(0, 5, 0, 0, 0);
|
||||
@ -197,6 +204,9 @@ tab_settings::load_preferences() {
|
||||
if (!cfg->Read(wxT("ask_before_overwriting"), &b))
|
||||
b = true;
|
||||
cb_ask_before_overwriting->SetValue(b);
|
||||
if (!cfg->Read(wxT("filenew_after_add_to_jobqueue"), &b))
|
||||
b = false;
|
||||
cb_filenew_after_add_to_jobqueue->SetValue(b);
|
||||
if (!cfg->Read(wxT("on_top"), &b))
|
||||
b = false;
|
||||
cb_on_top->SetValue(b);
|
||||
@ -213,6 +223,8 @@ tab_settings::save_preferences() {
|
||||
cb_autoset_output_filename->IsChecked());
|
||||
cfg->Write(wxT("ask_before_overwriting"),
|
||||
cb_ask_before_overwriting->IsChecked());
|
||||
cfg->Write(wxT("filenew_after_add_to_jobqueue"),
|
||||
cb_filenew_after_add_to_jobqueue->IsChecked());
|
||||
cfg->Write(wxT("on_top"), cb_on_top->IsChecked());
|
||||
cfg->Flush();
|
||||
}
|
||||
@ -291,5 +303,6 @@ BEGIN_EVENT_TABLE(tab_settings, wxPanel)
|
||||
EVT_BUTTON(ID_B_BROWSEMKVMERGE, tab_settings::on_browse)
|
||||
EVT_COMBOBOX(ID_COB_PRIORITY, tab_settings::on_xyz_selected)
|
||||
EVT_CHECKBOX(ID_CB_AUTOSET_OUTPUT_FILENAME, tab_settings::on_xyz_selected)
|
||||
EVT_CHECKBOX(ID_CB_NEW_AFTER_ADD_TO_JOBQUEUE, tab_settings::on_xyz_selected)
|
||||
EVT_CHECKBOX(ID_CB_ON_TOP, tab_settings::on_on_top_selected)
|
||||
END_EVENT_TABLE();
|
||||
|
@ -28,6 +28,7 @@
|
||||
#define ID_CB_AUTOSET_OUTPUT_FILENAME 15003
|
||||
#define ID_CB_ASK_BEFORE_OVERWRITING 15004
|
||||
#define ID_CB_ON_TOP 15005
|
||||
#define ID_CB_NEW_AFTER_ADD_TO_JOBQUEUE 15006
|
||||
|
||||
class tab_settings: public wxPanel {
|
||||
DECLARE_CLASS(tab_settings);
|
||||
@ -36,6 +37,7 @@ public:
|
||||
wxTextCtrl *tc_mkvmerge;
|
||||
wxCheckBox *cb_show_commandline, *cb_autoset_output_filename;
|
||||
wxCheckBox *cb_ask_before_overwriting, *cb_on_top;
|
||||
wxCheckBox *cb_filenew_after_add_to_jobqueue;
|
||||
wxComboBox *cob_priority;
|
||||
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user