perf: prefer absl::flat_hash_set
over std::set
when sorted order is not needed (#46440)
* perf: use an absl::flat_hash_set for UsbChooserContext::ephemeral_devices_ Co-authored-by: Charles Kerr <charles@charleskerr.com> * perf: use an absl::flat_hash_set for GlobalMenuBarRegistrarX11::live_windows_ Co-authored-by: Charles Kerr <charles@charleskerr.com> * perf: use an absl::flat_hash_set for NativeWindowViews::forwarding_windows_ Co-authored-by: Charles Kerr <charles@charleskerr.com> * perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::guest_host_views_ perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::proxy_views_ Co-authored-by: Charles Kerr <charles@charleskerr.com> * perf: use an absl::flat_hash_set for NativeWindow::injected_frames_ Co-authored-by: Charles Kerr <charles@charleskerr.com> * perf: use an absl::flat_hash_set for NativeWindow::background_throttling_sources_ Co-authored-by: Charles Kerr <charles@charleskerr.com> --------- Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Charles Kerr <charles@charleskerr.com>
This commit is contained in:
parent
99c3728a93
commit
5a6ed32592
7 changed files with 14 additions and 15 deletions
|
@ -6,7 +6,6 @@
|
|||
#define ELECTRON_SHELL_BROWSER_OSR_OSR_RENDER_WIDGET_HOST_VIEW_H_
|
||||
|
||||
#include <memory>
|
||||
#include <set>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
|
@ -28,6 +27,7 @@
|
|||
#include "shell/browser/osr/osr_host_display_client.h"
|
||||
#include "shell/browser/osr/osr_video_consumer.h"
|
||||
#include "shell/browser/osr/osr_view_proxy.h"
|
||||
#include "third_party/abseil-cpp/absl/container/flat_hash_set.h"
|
||||
#include "third_party/blink/public/mojom/widget/record_content_to_visible_time_request.mojom-forward.h"
|
||||
#include "third_party/skia/include/core/SkBitmap.h"
|
||||
#include "ui/base/ime/text_input_client.h"
|
||||
|
@ -277,8 +277,8 @@ class OffScreenRenderWidgetHostView
|
|||
raw_ptr<OffScreenRenderWidgetHostView> parent_host_view_ = nullptr;
|
||||
raw_ptr<OffScreenRenderWidgetHostView> popup_host_view_ = nullptr;
|
||||
raw_ptr<OffScreenRenderWidgetHostView> child_host_view_ = nullptr;
|
||||
std::set<OffScreenRenderWidgetHostView*> guest_host_views_;
|
||||
std::set<OffscreenViewProxy*> proxy_views_;
|
||||
absl::flat_hash_set<OffScreenRenderWidgetHostView*> guest_host_views_;
|
||||
absl::flat_hash_set<OffscreenViewProxy*> proxy_views_;
|
||||
|
||||
const bool transparent_;
|
||||
const bool offscreen_use_shared_texture_;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue