CDialogPromptNewerFile::CDialogPromptNewerFile( wxWindow *parent, const wxString &sFileName, const wxString &sNewest) : wxDialog( parent,wxID_ANY,"Newer file available", wxDefaultPosition, wxDefaultSize, mainApp::DIALOG_STYLE) { wxFileName fn1(sFileName); wxFileName fn2(sNewest); wxString sPrompt; const wxChar *ButtonText[4] = { wxS("Open the newer file"), // yes wxS("Open the selected file"), // no wxS("Do not open either file"), // cancel wxS("View folder before deciding") // view }; SetupURL(fn2); sPrompt.Alloc(1024); sPrompt = "The folder containing the selected file,\n "; sPrompt.Append(fn1.GetFullName()); sPrompt.Append("\n"); AFTER_FILE_NAMES(sPrompt,fn2.GetFullName()); Setup(sPrompt,ButtonText); }
CDialogPromptNewerFile::CDialogPromptNewerFile( wxWindow *parent, const SET_FILE_NAMES &setFileNames, const wxString &sNewest) : wxDialog( parent,wxID_ANY,"Newer file available", wxDefaultPosition, wxDefaultSize, mainApp::DIALOG_STYLE) { wxFileName fnNew(sNewest); wxString sPrompt; sPrompt.Alloc(1024); const wxChar *ButtonText[4] = { wxS("Open the newer file, also"), wxS("Open the selected files"), wxS("Do not open any of the above files"), wxS("View folder before deciding") }; SetupURL(fnNew); sPrompt = "The folder containing the selected files:\n"; for(SET_FILE_NAMES::const_iterator itr = setFileNames.begin(); itr != setFileNames.end(); ++itr) { wxFileName fn(*itr); sPrompt.Append(" "); sPrompt.Append(fn.GetFullName()); sPrompt.Append("\n"); } AFTER_FILE_NAMES(sPrompt,fnNew.GetFullName()); Setup(sPrompt,ButtonText); }
OP_STATUS OperaBlanker::GenerateData() { RETURN_IF_ERROR(SetupURL(NO_CACHE | SKIP_BOM)); return FinishURL(); }