Add target disposition and user gesture parameters to CefLifeSpanHandler::OnBeforePopup (issue #1525).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2053 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2015-03-06 21:38:38 +00:00
parent 36fd5e3ed0
commit 5de989e306
11 changed files with 83 additions and 23 deletions

View File

@@ -475,6 +475,8 @@ class PopupTestHandler : public TestHandler {
CefRefPtr<CefFrame> frame,
const CefString& target_url,
const CefString& target_frame_name,
WindowOpenDisposition target_disposition,
bool user_gesture,
const CefPopupFeatures& popupFeatures,
CefWindowInfo& windowInfo,
CefRefPtr<CefClient>& client,
@@ -484,6 +486,14 @@ class PopupTestHandler : public TestHandler {
const std::string& url = target_url;
EXPECT_STREQ(url.c_str(), popup_url_.c_str());
EXPECT_EQ(WOD_NEW_FOREGROUND_TAB, target_disposition);
if (mode_ == MODE_WINDOW_OPEN)
EXPECT_FALSE(user_gesture);
else
EXPECT_TRUE(user_gesture);
return false;
}