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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/extensions/extensions-sidebar.html

Issue 1905493002: Make the extension's sidebar pane auto-resizable. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix layout tests Created 4 years, 7 months 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
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script> 3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/extensions-test.js"></script> 4 <script src="../../http/tests/inspector/extensions-test.js"></script>
5 <script type="text/javascript"> 5 <script type="text/javascript">
6 6
7 function initialize_extensionsSidebarTest() 7 function initialize_extensionsSidebarTest()
8 { 8 {
9 InspectorTest.dumpSidebarContent = function(panelName, callback) 9 InspectorTest.dumpSidebarContent = function(panelName, callback)
10 { 10 {
(...skipping 26 matching lines...) Expand all
37 } 37 }
38 38
39 function extension_sidebarSetPage(panelName, nextTest) 39 function extension_sidebarSetPage(panelName, nextTest)
40 { 40 {
41 function onSidebarCreated(sidebar) 41 function onSidebarCreated(sidebar)
42 { 42 {
43 output("Sidebar created"); 43 output("Sidebar created");
44 dumpObject(sidebar); 44 dumpObject(sidebar);
45 function onShown(win) 45 function onShown(win)
46 { 46 {
47 output("sidebar height " + win.document.documentElement.getBoundingC lientRect().height); 47 var sidebarHeight = win.document.documentElement.getBoundingClientRe ct().height;
48 if (win.innerHeight !== sidebarHeight)
49 output("sidebar height mismatch, expected: " + win.innerHeight + ", actual:" + sidebarHeight);
48 sidebar.onShown.removeListener(onShown); 50 sidebar.onShown.removeListener(onShown);
49 nextTest(); 51 nextTest();
50 } 52 }
51 sidebar.onShown.addListener(onShown); 53 sidebar.onShown.addListener(onShown);
52 var basePath = location.pathname.replace(/\/[^/]*$/, "/"); 54 var basePath = location.pathname.replace(/\/[^/]*$/, "/");
53 sidebar.setPage(basePath + "extension-sidebar.html"); 55 sidebar.setPage(basePath + "extension-sidebar.html");
54 extension_showPanel(panelName, extension_expandSidebar.bind(null, panelN ame)); 56 extension_showPanel(panelName, extension_expandSidebar.bind(null, panelN ame));
55 } 57 }
56 output("Call createSidebarPane for " + panelName); 58 output("Call createSidebarPane for " + panelName);
57 webInspector.panels[panelName].createSidebarPane("Test Sidebar", onSidebarCr eated); 59 webInspector.panels[panelName].createSidebarPane("Test Sidebar", onSidebarCr eated);
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 } 231 }
230 webInspector.panels[panelName].createSidebarPane("Sidebar Test: replace pag e with object", onSidebarCreated); 232 webInspector.panels[panelName].createSidebarPane("Sidebar Test: replace pag e with object", onSidebarCreated);
231 } 233 }
232 234
233 </script> 235 </script>
234 </head> 236 </head>
235 <body onload="runTest()"> 237 <body onload="runTest()">
236 <p>Tests sidebars in WebInspector extensions API</p> 238 <p>Tests sidebars in WebInspector extensions API</p>
237 </body> 239 </body>
238 </html> 240 </html>
OLDNEW
« no previous file with comments | « AUTHORS ('k') | third_party/WebKit/LayoutTests/inspector/extensions/extensions-sidebar-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698