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

Side by Side Diff: headless/lib/browser/headless_devtools_manager_delegate.h

Issue 2896763002: Implement window management devtools commands for headless. (Closed)
Patch Set: nit and rebase Created 3 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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_ 5 #ifndef HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_
6 #define HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_ 6 #define HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 const base::DictionaryValue* params); 55 const base::DictionaryValue* params);
56 std::unique_ptr<base::DictionaryValue> CloseTarget( 56 std::unique_ptr<base::DictionaryValue> CloseTarget(
57 int command_id, 57 int command_id,
58 const base::DictionaryValue* params); 58 const base::DictionaryValue* params);
59 std::unique_ptr<base::DictionaryValue> CreateBrowserContext( 59 std::unique_ptr<base::DictionaryValue> CreateBrowserContext(
60 int command_id, 60 int command_id,
61 const base::DictionaryValue* params); 61 const base::DictionaryValue* params);
62 std::unique_ptr<base::DictionaryValue> DisposeBrowserContext( 62 std::unique_ptr<base::DictionaryValue> DisposeBrowserContext(
63 int command_id, 63 int command_id,
64 const base::DictionaryValue* params); 64 const base::DictionaryValue* params);
65 std::unique_ptr<base::DictionaryValue> GetWindowForTarget(
66 int command_id,
67 const base::DictionaryValue* params);
68 std::unique_ptr<base::DictionaryValue> GetWindowBounds(
69 int command_id,
70 const base::DictionaryValue* params);
71 std::unique_ptr<base::DictionaryValue> SetWindowBounds(
72 int command_id,
73 const base::DictionaryValue* params);
65 void PrintToPDF(content::DevToolsAgentHost* agent_host, 74 void PrintToPDF(content::DevToolsAgentHost* agent_host,
66 int command_id, 75 int command_id,
67 const base::DictionaryValue* params, 76 const base::DictionaryValue* params,
68 const CommandCallback& callback); 77 const CommandCallback& callback);
69 78
70 base::WeakPtr<HeadlessBrowserImpl> browser_; 79 base::WeakPtr<HeadlessBrowserImpl> browser_;
71 80
72 using CommandMemberCallback = 81 using CommandMemberCallback =
73 base::Callback<std::unique_ptr<base::DictionaryValue>( 82 base::Callback<std::unique_ptr<base::DictionaryValue>(
74 int command_id, 83 int command_id,
75 const base::DictionaryValue* params)>; 84 const base::DictionaryValue* params)>;
76 using AsyncCommandMemberCallback = 85 using AsyncCommandMemberCallback =
77 base::Callback<void(content::DevToolsAgentHost* agent_host, 86 base::Callback<void(content::DevToolsAgentHost* agent_host,
78 int command_id, 87 int command_id,
79 const base::DictionaryValue* params, 88 const base::DictionaryValue* params,
80 const CommandCallback& callback)>; 89 const CommandCallback& callback)>;
81 std::map<std::string, CommandMemberCallback> command_map_; 90 std::map<std::string, CommandMemberCallback> command_map_;
82 std::map<std::string, AsyncCommandMemberCallback> async_command_map_; 91 std::map<std::string, AsyncCommandMemberCallback> async_command_map_;
83 }; 92 };
84 93
85 } // namespace headless 94 } // namespace headless
86 95
87 #endif // HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_ 96 #endif // HEADLESS_LIB_BROWSER_HEADLESS_DEVTOOLS_MANAGER_DELEGATE_H_
OLDNEW
« no previous file with comments | « headless/lib/browser/headless_devtools_client_impl.cc ('k') | headless/lib/browser/headless_devtools_manager_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698