OLD | NEW |
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 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 void InspectorFrontendClientLocal::changeAttachedWindowHeight(unsigned height) | 180 void InspectorFrontendClientLocal::changeAttachedWindowHeight(unsigned height) |
181 { | 181 { |
182 unsigned totalHeight = m_frontendPage->mainFrame()->view()->visibleHeight()
+ m_inspectorController->inspectedPage()->mainFrame()->view()->visibleHeight(); | 182 unsigned totalHeight = m_frontendPage->mainFrame()->view()->visibleHeight()
+ m_inspectorController->inspectedPage()->mainFrame()->view()->visibleHeight(); |
183 unsigned attachedHeight = constrainedAttachedWindowHeight(height, totalHeigh
t); | 183 unsigned attachedHeight = constrainedAttachedWindowHeight(height, totalHeigh
t); |
184 m_settings->setProperty(inspectorAttachedHeightSetting, String::number(attac
hedHeight)); | 184 m_settings->setProperty(inspectorAttachedHeightSetting, String::number(attac
hedHeight)); |
185 setAttachedWindowHeight(attachedHeight); | 185 setAttachedWindowHeight(attachedHeight); |
186 } | 186 } |
187 | 187 |
188 void InspectorFrontendClientLocal::openInNewTab(const String& url) | 188 void InspectorFrontendClientLocal::openInNewTab(const String& url) |
189 { | 189 { |
190 UserGestureIndicator indicator(DefinitelyProcessingUserGesture); | 190 UserGestureIndicator indicator(DefinitelyProcessingNewUserGesture); |
191 Page* page = m_inspectorController->inspectedPage(); | 191 Page* page = m_inspectorController->inspectedPage(); |
192 Frame* mainFrame = page->mainFrame(); | 192 Frame* mainFrame = page->mainFrame(); |
193 FrameLoadRequest request(mainFrame->document()->securityOrigin(), ResourceRe
quest(), "_blank"); | 193 FrameLoadRequest request(mainFrame->document()->securityOrigin(), ResourceRe
quest(), "_blank"); |
194 | 194 |
195 bool created; | 195 bool created; |
196 WindowFeatures windowFeatures; | 196 WindowFeatures windowFeatures; |
197 Frame* frame = WebCore::createWindow(mainFrame, mainFrame, request, windowFe
atures, created); | 197 Frame* frame = WebCore::createWindow(mainFrame, mainFrame, request, windowFe
atures, created); |
198 if (!frame) | 198 if (!frame) |
199 return; | 199 return; |
200 | 200 |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
314 { | 314 { |
315 if (m_frontendLoaded) | 315 if (m_frontendLoaded) |
316 m_frontendPage->mainFrame()->script()->executeScript("InspectorFrontendA
PI.dispatch(" + expression + ")"); | 316 m_frontendPage->mainFrame()->script()->executeScript("InspectorFrontendA
PI.dispatch(" + expression + ")"); |
317 else | 317 else |
318 m_evaluateOnLoad.append(expression); | 318 m_evaluateOnLoad.append(expression); |
319 } | 319 } |
320 | 320 |
321 } // namespace WebCore | 321 } // namespace WebCore |
322 | 322 |
323 #endif | 323 #endif |
OLD | NEW |