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:
Charles Kerr 2018-01-24 20:50:00 -06:00 committed by Cheng Zhao
parent 2435ffaf09
commit a5a068b2ee

View file

@ -36,7 +36,9 @@ void AtomJavaScriptDialogManager::RunJavaScriptDialog(
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 &&
dialog_type != JavaScriptDialogType::JAVASCRIPT_DIALOG_TYPE_CONFIRM) {
@ -62,8 +64,8 @@ void AtomJavaScriptDialogManager::RunJavaScriptDialog(
atom::ShowMessageBox(NativeWindow::FromWebContents(web_contents),
atom::MessageBoxType::MESSAGE_BOX_TYPE_NONE, buttons, -1,
0, atom::MessageBoxOptions::MESSAGE_BOX_NONE, "",
base::UTF16ToUTF8(message_text), "", checkbox_string, false,
gfx::ImageSkia(),
base::UTF16ToUTF8(message_text), "", checkbox_string,
false, gfx::ImageSkia(),
base::Bind(&OnMessageBoxCallback, callback, origin,
&origin_counts_));
}