| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <functional> |
| 10 #include <map> | 11 #include <map> |
| 11 #include <set> | 12 #include <set> |
| 12 #include <string> | 13 #include <string> |
| 13 | 14 |
| 14 #include "base/compiler_specific.h" | 15 #include "base/compiler_specific.h" |
| 15 #include "base/containers/scoped_ptr_hash_map.h" | 16 #include "base/containers/scoped_ptr_hash_map.h" |
| 16 #include "base/gtest_prod_util.h" | 17 #include "base/gtest_prod_util.h" |
| 17 #include "base/macros.h" | 18 #include "base/macros.h" |
| 18 #include "base/memory/scoped_ptr.h" | 19 #include "base/memory/scoped_ptr.h" |
| 19 #include "base/observer_list.h" | 20 #include "base/observer_list.h" |
| (...skipping 943 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 963 | 964 |
| 964 // Finds the new RenderWidgetHost and returns it. Note that this can only be | 965 // Finds the new RenderWidgetHost and returns it. Note that this can only be |
| 965 // called once as this call also removes it from the internal map. | 966 // called once as this call also removes it from the internal map. |
| 966 RenderWidgetHostView* GetCreatedWidget(int route_id); | 967 RenderWidgetHostView* GetCreatedWidget(int route_id); |
| 967 | 968 |
| 968 // Finds the new WebContentsImpl by route_id, initializes it for | 969 // Finds the new WebContentsImpl by route_id, initializes it for |
| 969 // renderer-initiated creation, and returns it. Note that this can only be | 970 // renderer-initiated creation, and returns it. Note that this can only be |
| 970 // called once as this call also removes it from the internal map. | 971 // called once as this call also removes it from the internal map. |
| 971 WebContentsImpl* GetCreatedWindow(int route_id); | 972 WebContentsImpl* GetCreatedWindow(int route_id); |
| 972 | 973 |
| 974 // Sends an IPC message to every RenderView in the FrameTree. Returns the |
| 975 // number of messages sent. |
| 976 int SendToAllViews(IPC::Message* msg); |
| 977 |
| 973 // Tracking loading progress ------------------------------------------------- | 978 // Tracking loading progress ------------------------------------------------- |
| 974 | 979 |
| 975 // Resets the tracking state of the current load progress. | 980 // Resets the tracking state of the current load progress. |
| 976 void ResetLoadProgressState(); | 981 void ResetLoadProgressState(); |
| 977 | 982 |
| 978 // Notifies the delegate that the load progress was updated. | 983 // Notifies the delegate that the load progress was updated. |
| 979 void SendChangeLoadProgress(); | 984 void SendChangeLoadProgress(); |
| 980 | 985 |
| 981 // Misc non-view stuff ------------------------------------------------------- | 986 // Misc non-view stuff ------------------------------------------------------- |
| 982 | 987 |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1326 // Adds/removes a callback called on creation of each new WebContents. | 1331 // Adds/removes a callback called on creation of each new WebContents. |
| 1327 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); | 1332 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1328 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); | 1333 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1329 | 1334 |
| 1330 DISALLOW_COPY_AND_ASSIGN(FriendZone); | 1335 DISALLOW_COPY_AND_ASSIGN(FriendZone); |
| 1331 }; | 1336 }; |
| 1332 | 1337 |
| 1333 } // namespace content | 1338 } // namespace content |
| 1334 | 1339 |
| 1335 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1340 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| OLD | NEW |