mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update source files for bracket style
This commit is contained in:
@@ -55,8 +55,9 @@ class TitleTestHandler : public TestHandler {
|
||||
const CefString& title) override {
|
||||
// Ignore the 2nd OnTitleChange call which arrives after navigation
|
||||
// completion.
|
||||
if (got_title_change_)
|
||||
if (got_title_change_) {
|
||||
return;
|
||||
}
|
||||
|
||||
std::string title_str = title;
|
||||
if (step_ == 0 || step_ == 2) {
|
||||
@@ -81,8 +82,9 @@ class TitleTestHandler : public TestHandler {
|
||||
bool isLoading,
|
||||
bool canGoBack,
|
||||
bool canGoForward) override {
|
||||
if (isLoading)
|
||||
if (isLoading) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Call NextIfReady asynchronously because an additional call to
|
||||
// OnTitleChange will be triggered later in the current call stack due to
|
||||
@@ -95,8 +97,9 @@ class TitleTestHandler : public TestHandler {
|
||||
|
||||
private:
|
||||
void NextIfReady(CefRefPtr<CefBrowser> browser) {
|
||||
if (!got_title_change_ || !got_loading_state_change_)
|
||||
if (!got_title_change_ || !got_loading_state_change_) {
|
||||
return;
|
||||
}
|
||||
|
||||
got_title_change_ = false;
|
||||
got_loading_state_change_ = false;
|
||||
@@ -120,8 +123,9 @@ class TitleTestHandler : public TestHandler {
|
||||
}
|
||||
|
||||
void DestroyTest() override {
|
||||
for (int i = 0; i < 5; ++i)
|
||||
for (int i = 0; i < 5; ++i) {
|
||||
EXPECT_TRUE(got_title_[i]) << "step " << i;
|
||||
}
|
||||
|
||||
TestHandler::DestroyTest();
|
||||
}
|
||||
@@ -287,8 +291,9 @@ class ConsoleTestHandler : public TestHandler {
|
||||
bool isLoading,
|
||||
bool canGoBack,
|
||||
bool canGoForward) override {
|
||||
if (isLoading)
|
||||
if (isLoading) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Print console message after loading.
|
||||
browser->GetMainFrame()->ExecuteJavaScript("printMessage()", config_.source,
|
||||
@@ -485,8 +490,9 @@ class LoadingProgressTestHandler : public TestHandler {
|
||||
bool isLoading,
|
||||
bool canGoBack,
|
||||
bool canGoForward) override {
|
||||
if (isLoading)
|
||||
if (isLoading) {
|
||||
return;
|
||||
}
|
||||
|
||||
DestroyTest();
|
||||
}
|
||||
|
Reference in New Issue
Block a user