Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Side by Side Diff: Source/web/tests/WebFrameTest.cpp

Issue 782243003: Remove temporary code in FullscreenController and WebWidgetClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@webframeclient_fullscreen
Patch Set: rebase and fixes Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/web/FullscreenController.cpp ('k') | public/web/WebFrameClient.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 671 matching lines...) Expand 10 before | Expand all | Expand 10 after
682 } 682 }
683 683
684 class FixedLayoutTestWebViewClient : public FrameTestHelpers::TestWebViewClient { 684 class FixedLayoutTestWebViewClient : public FrameTestHelpers::TestWebViewClient {
685 public: 685 public:
686 virtual WebScreenInfo screenInfo() override { return m_screenInfo; } 686 virtual WebScreenInfo screenInfo() override { return m_screenInfo; }
687 687
688 WebScreenInfo m_screenInfo; 688 WebScreenInfo m_screenInfo;
689 }; 689 };
690 690
691 class FakeCompositingWebViewClient : public FixedLayoutTestWebViewClient { 691 class FakeCompositingWebViewClient : public FixedLayoutTestWebViewClient {
692 public:
693 virtual bool enterFullScreen() override { return true; }
694 }; 692 };
695 693
696 // Viewport settings need to be set before the page gets loaded 694 // Viewport settings need to be set before the page gets loaded
697 static void enableViewportSettings(WebSettings* settings) 695 static void enableViewportSettings(WebSettings* settings)
698 { 696 {
699 settings->setViewportMetaEnabled(true); 697 settings->setViewportMetaEnabled(true);
700 settings->setViewportEnabled(true); 698 settings->setViewportEnabled(true);
701 settings->setMainFrameResizesAreOrientationChanges(true); 699 settings->setMainFrameResizesAreOrientationChanges(true);
702 settings->setShrinksViewportContentToFit(true); 700 settings->setShrinksViewportContentToFit(true);
703 } 701 }
(...skipping 6220 matching lines...) Expand 10 before | Expand all | Expand 10 after
6924 EXPECT_EQ(1u, frameClient.navigationalDataReceivedCount()); 6922 EXPECT_EQ(1u, frameClient.navigationalDataReceivedCount());
6925 6923
6926 // Neither should a page reload. 6924 // Neither should a page reload.
6927 localFrame->reload(); 6925 localFrame->reload();
6928 EXPECT_EQ(4u, frameClient.provisionalLoadCount()); 6926 EXPECT_EQ(4u, frameClient.provisionalLoadCount());
6929 EXPECT_FALSE(frameClient.wasLastProvisionalLoadATransition()); 6927 EXPECT_FALSE(frameClient.wasLastProvisionalLoadATransition());
6930 EXPECT_EQ(1u, frameClient.navigationalDataReceivedCount()); 6928 EXPECT_EQ(1u, frameClient.navigationalDataReceivedCount());
6931 } 6929 }
6932 6930
6933 } // namespace 6931 } // namespace
OLDNEW
« no previous file with comments | « Source/web/FullscreenController.cpp ('k') | public/web/WebFrameClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698