fix cpplint errors
atom/browser/atom_javascript_dialog_manager.cc:39: Lines should be <= 80 characters long [whitespace/line_length] [2] atom/browser/atom_javascript_dialog_manager.cc:39: If/else bodies with multiple statements require braces [readability/braces] [4] atom/browser/atom_javascript_dialog_manager.cc:62: Lines should be <= 80 characters long [whitespace/line_length] [2] atom/browser/atom_javascript_dialog_manager.cc:89: If/else bodies with multiple statements require braces [readability/braces] [4]
This commit is contained in:
parent
2435ffaf09
commit
a5a068b2ee
1 changed files with 5 additions and 3 deletions
|
@ -36,7 +36,9 @@ void AtomJavaScriptDialogManager::RunJavaScriptDialog(
|
||||||
origin_counts_[origin] = 0;
|
origin_counts_[origin] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (origin_counts_[origin] == -1) return callback.Run(false, base::string16());;
|
if (origin_counts_[origin] == -1) {
|
||||||
|
return callback.Run(false, base::string16());
|
||||||
|
}
|
||||||
|
|
||||||
if (dialog_type != JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_ALERT &&
|
if (dialog_type != JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_ALERT &&
|
||||||
dialog_type != JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_CONFIRM) {
|
dialog_type != JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_CONFIRM) {
|
||||||
|
@ -62,8 +64,8 @@ void AtomJavaScriptDialogManager::RunJavaScriptDialog(
|
||||||
atom::ShowMessageBox(NativeWindow::FromWebContents(web_contents),
|
atom::ShowMessageBox(NativeWindow::FromWebContents(web_contents),
|
||||||
atom::MessageBoxType::MESSAGE_BOX_TYPE_NONE, buttons, -1,
|
atom::MessageBoxType::MESSAGE_BOX_TYPE_NONE, buttons, -1,
|
||||||
0, atom::MessageBoxOptions::MESSAGE_BOX_NONE, "",
|
0, atom::MessageBoxOptions::MESSAGE_BOX_NONE, "",
|
||||||
base::UTF16ToUTF8(message_text), "", checkbox_string, false,
|
base::UTF16ToUTF8(message_text), "", checkbox_string,
|
||||||
gfx::ImageSkia(),
|
false, gfx::ImageSkia(),
|
||||||
base::Bind(&OnMessageBoxCallback, callback, origin,
|
base::Bind(&OnMessageBoxCallback, callback, origin,
|
||||||
&origin_counts_));
|
&origin_counts_));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue