diff --git a/ash/message_center/notifier_settings_view.cc b/ash/message_center/notifier_settings_view.cc index 0257be62..5faf222 100644 --- a/ash/message_center/notifier_settings_view.cc +++ b/ash/message_center/notifier_settings_view.cc
@@ -61,7 +61,7 @@ namespace { -const int kEntryHeight = 48; +const int kNotifierButtonWrapperHeight = 48; const int kHorizontalMargin = 12; const int kEntryIconSize = 20; const int kInternalHorizontalSpacing = 16; @@ -102,23 +102,29 @@ constexpr gfx::Insets kTopLabelPadding(16, 18, 15, 18); const int kQuietModeViewSpacing = 18; -constexpr gfx::Insets kHeaderViewPadding(4, 0, 4, 0); +constexpr gfx::Insets kHeaderViewPadding(4, 0); constexpr gfx::Insets kQuietModeViewPadding(0, 18, 0, 0); constexpr gfx::Insets kQuietModeLabelPadding(16, 0, 15, 0); -constexpr gfx::Insets kQuietModeTogglePadding(0, 14, 0, 14); -constexpr SkColor kTopLabelColor = SkColorSetRGB(0x42, 0x85, 0xF4); -constexpr SkColor kLabelColor = SkColorSetARGB(0xDE, 0x0, 0x0, 0x0); -constexpr SkColor kTopBorderColor = SkColorSetARGB(0x1F, 0x0, 0x0, 0x0); +constexpr gfx::Insets kQuietModeTogglePadding(0, 14); +constexpr SkColor kTopLabelColor = gfx::kGoogleBlue500; +constexpr SkColor kLabelColor = SkColorSetA(SK_ColorBLACK, 0xDE); +constexpr SkColor kTopBorderColor = SkColorSetA(SK_ColorBLACK, 0x1F); +constexpr SkColor kDisabledNotifierFilterColor = + SkColorSetA(SK_ColorWHITE, 0xB8); const int kLabelFontSizeDelta = 1; -// EntryView ------------------------------------------------------------------ +// NotifierButtonWrapperView --------------------------------------------------- -// The view to guarantee the 48px height and place the contents at the -// middle. It also guarantee the left margin. -class EntryView : public views::View { +// A wrapper view of NotifierButton to guarantee the fixed height +// |kNotifierButtonWrapperHeight|. The button is placed in the middle of +// the wrapper view by giving padding to the top and the bottom. +// The view is focusable and provides focus painter. When the button is disabled +// (NotifierUiData.enforced), it also applies filter to make the color of the +// button dim. +class NotifierButtonWrapperView : public views::View { public: - explicit EntryView(views::View* contents); - ~EntryView() override; + explicit NotifierButtonWrapperView(views::View* contents); + ~NotifierButtonWrapperView() override; // views::View: void Layout() override; @@ -131,62 +137,96 @@ void OnBlur() override; private: + // Initialize |disabled_filter_|. Should be called once. + void CreateDisabledFilter(); + std::unique_ptr<views::Painter> focus_painter_; - DISALLOW_COPY_AND_ASSIGN(EntryView); + // NotifierButton to wrap. + views::View* contents_; + + // A view to add semi-transparent filter on top of |contents_|. + // It is only visible when NotifierButton is disabled (e.g. the setting is + // enforced by administrator.) The color of the NotifierButton would be dim + // and users notice they can't change the setting. + views::View* disabled_filter_ = nullptr; + + DISALLOW_COPY_AND_ASSIGN(NotifierButtonWrapperView); }; -EntryView::EntryView(views::View* contents) - : focus_painter_(CreateFocusPainter()) { +NotifierButtonWrapperView::NotifierButtonWrapperView(views::View* contents) + : focus_painter_(CreateFocusPainter()), contents_(contents) { AddChildView(contents); } -EntryView::~EntryView() = default; +NotifierButtonWrapperView::~NotifierButtonWrapperView() = default; -void EntryView::Layout() { - DCHECK_EQ(1, child_count()); - views::View* content = child_at(0); - int content_width = width(); - int content_height = content->GetHeightForWidth(content_width); - int y = std::max((height() - content_height) / 2, 0); - content->SetBounds(0, y, content_width, content_height); +void NotifierButtonWrapperView::Layout() { + int contents_width = width(); + int contents_height = contents_->GetHeightForWidth(contents_width); + int y = std::max((height() - contents_height) / 2, 0); + contents_->SetBounds(0, y, contents_width, contents_height); + + // Since normally we don't show |disabled_filter_|, initialize it lazily. + if (!contents_->enabled()) { + if (!disabled_filter_) + CreateDisabledFilter(); + disabled_filter_->SetVisible(true); + gfx::Rect filter_bounds = GetContentsBounds(); + filter_bounds.set_width(filter_bounds.width() - kEntryIconSize); + disabled_filter_->SetBoundsRect(filter_bounds); + } else if (disabled_filter_) { + disabled_filter_->SetVisible(false); + } + + SetFocusBehavior(contents_->enabled() ? FocusBehavior::ALWAYS + : FocusBehavior::NEVER); } -gfx::Size EntryView::CalculatePreferredSize() const { - return gfx::Size(kWidth, kEntryHeight); +gfx::Size NotifierButtonWrapperView::CalculatePreferredSize() const { + return gfx::Size(kWidth, kNotifierButtonWrapperHeight); } -void EntryView::GetAccessibleNodeData(ui::AXNodeData* node_data) { - DCHECK_EQ(1, child_count()); - child_at(0)->GetAccessibleNodeData(node_data); +void NotifierButtonWrapperView::GetAccessibleNodeData( + ui::AXNodeData* node_data) { + contents_->GetAccessibleNodeData(node_data); } -void EntryView::OnFocus() { +void NotifierButtonWrapperView::OnFocus() { views::View::OnFocus(); ScrollRectToVisible(GetLocalBounds()); // We render differently when focused. SchedulePaint(); } -bool EntryView::OnKeyPressed(const ui::KeyEvent& event) { - return child_at(0)->OnKeyPressed(event); +bool NotifierButtonWrapperView::OnKeyPressed(const ui::KeyEvent& event) { + return contents_->OnKeyPressed(event); } -bool EntryView::OnKeyReleased(const ui::KeyEvent& event) { - return child_at(0)->OnKeyReleased(event); +bool NotifierButtonWrapperView::OnKeyReleased(const ui::KeyEvent& event) { + return contents_->OnKeyReleased(event); } -void EntryView::OnPaint(gfx::Canvas* canvas) { +void NotifierButtonWrapperView::OnPaint(gfx::Canvas* canvas) { View::OnPaint(canvas); views::Painter::PaintFocusPainter(this, canvas, focus_painter_.get()); } -void EntryView::OnBlur() { +void NotifierButtonWrapperView::OnBlur() { View::OnBlur(); // We render differently when focused. SchedulePaint(); } +void NotifierButtonWrapperView::CreateDisabledFilter() { + DCHECK(!disabled_filter_); + disabled_filter_ = new views::View; + disabled_filter_->SetBackground( + views::CreateSolidBackground(kDisabledNotifierFilterColor)); + disabled_filter_->set_can_process_events_within_subtree(false); + AddChildView(disabled_filter_); +} + // ScrollContentsView ---------------------------------------------------------- class ScrollContentsView : public views::View { @@ -268,8 +308,7 @@ notifier_id_(notifier_ui_data.notifier_id), icon_view_(new views::ImageView()), name_view_(new views::Label(notifier_ui_data.name)), - checkbox_(new views::Checkbox(base::string16(), true /* force_md */)), - learn_more_(nullptr) { + checkbox_(new views::Checkbox(base::string16(), true /* force_md */)) { name_view_->SetAutoColorReadabilityEnabled(false); name_view_->SetEnabledColor(kLabelColor); // "Roboto-Regular, 13sp" is specified in the mock. @@ -304,12 +343,16 @@ // The image itself is quite small, this large invisible border creates a // much bigger click target. learn_more_->SetBorder(views::CreateEmptyBorder( - learn_more_border_height, learn_more_border_width, - learn_more_border_height, learn_more_border_width)); + gfx::Insets(learn_more_border_height, learn_more_border_width))); learn_more_->SetImageAlignment(views::ImageButton::ALIGN_CENTER, views::ImageButton::ALIGN_MIDDLE); } + if (notifier_ui_data.enforced) { + Button::SetEnabled(false); + checkbox_->SetEnabled(false); + } + UpdateIconImage(notifier_ui_data.icon); } @@ -394,19 +437,27 @@ // Add a padding column which contains expandable blank space. cs->AddPaddingColumn(1, 0); + layout->StartRow(0, 0); + layout->AddView(checkbox_); + layout->AddView(icon_view_); + layout->AddView(name_view_); + // Add a column for the learn more button if necessary. if (learn_more_) { cs->AddPaddingColumn(0, kInternalHorizontalSpacing); cs->AddColumn(GridLayout::CENTER, GridLayout::CENTER, 0, GridLayout::USE_PREF, 0, 0); + layout->AddView(learn_more_); } - layout->StartRow(0, 0); - layout->AddView(checkbox_); - layout->AddView(icon_view_); - layout->AddView(name_view_); - if (learn_more_) - layout->AddView(learn_more_); + if (!enabled()) { + views::ImageView* policy_enforced_icon = new views::ImageView(); + policy_enforced_icon->SetImage(gfx::CreateVectorIcon( + kSystemMenuBusinessIcon, kEntryIconSize, gfx::kChromeIconGrey)); + cs->AddColumn(GridLayout::CENTER, GridLayout::CENTER, 0, GridLayout::FIXED, + kEntryIconSize, 0); + layout->AddView(policy_enforced_icon); + } Layout(); } @@ -534,10 +585,10 @@ size_t notifier_count = ui_data.size(); for (size_t i = 0; i < notifier_count; ++i) { NotifierButton* button = new NotifierButton(*ui_data[i], this); - EntryView* entry = new EntryView(button); + NotifierButtonWrapperView* wrapper = new NotifierButtonWrapperView(button); - entry->SetFocusBehavior(FocusBehavior::ALWAYS); - contents_view->AddChildView(entry); + wrapper->SetFocusBehavior(FocusBehavior::ALWAYS); + contents_view->AddChildView(wrapper); buttons_.insert(button); }
diff --git a/ash/message_center/notifier_settings_view_unittest.cc b/ash/message_center/notifier_settings_view_unittest.cc index e61c0c4..7d197919 100644 --- a/ash/message_center/notifier_settings_view_unittest.cc +++ b/ash/message_center/notifier_settings_view_unittest.cc
@@ -62,11 +62,11 @@ ui_data.push_back(mojom::NotifierUiData::New( NotifierId(NotifierId::APPLICATION, "id"), base::ASCIIToUTF16("title"), true /* has_advanced_settings */, - true /* enabled */, gfx::ImageSkia())); + true /* enabled */, false /* enforced */, gfx::ImageSkia())); ui_data.push_back(mojom::NotifierUiData::New( NotifierId(NotifierId::APPLICATION, "id2"), base::ASCIIToUTF16("other title"), false /* has_advanced_settings */, - false /* enabled */, gfx::ImageSkia())); + false /* enabled */, false /* enforced */, gfx::ImageSkia())); } std::move(callback).Run(std::move(ui_data));
diff --git a/ash/public/interfaces/ash_message_center_controller.mojom b/ash/public/interfaces/ash_message_center_controller.mojom index f42ce2c..b430048 100644 --- a/ash/public/interfaces/ash_message_center_controller.mojom +++ b/ash/public/interfaces/ash_message_center_controller.mojom
@@ -24,6 +24,9 @@ // True if notifications from the notifier are presently enabled. bool enabled; + // True if the setting is enforced by administrator and the user can't change. + bool enforced; + // An icon displayed next to the name. gfx.mojom.ImageSkia? icon; };
diff --git a/ash/wm/client_controlled_state.cc b/ash/wm/client_controlled_state.cc index b402b92..664d290f 100644 --- a/ash/wm/client_controlled_state.cc +++ b/ash/wm/client_controlled_state.cc
@@ -51,7 +51,7 @@ bool was_pinned = window_state->IsPinned(); bool was_trusted_pinned = window_state->IsTrustedPinned(); - EnterNextState(window_state, next_state_type); + EnterNextState(window_state, next_state_type, kAnimationCrossFade); VLOG(1) << "Processing Pinned Transtion: event=" << event->type() << ", state=" << old_state_type << "=>" << next_state_type @@ -143,17 +143,23 @@ const WMEvent* event) { switch (event->type()) { case WM_EVENT_SET_BOUNDS: { - // TODO(oshima): Send the set bounds request to client. - const SetBoundsEvent* set_bounds_event = - static_cast<const SetBoundsEvent*>(event); + const gfx::Rect& bounds = + static_cast<const SetBoundsEvent*>(event)->requested_bounds(); if (set_bounds_locally_) { - window_state->SetBoundsDirect(set_bounds_event->requested_bounds()); + switch (bounds_change_animation_type_) { + case kAnimationNone: + window_state->SetBoundsDirect(bounds); + break; + case kAnimationCrossFade: + window_state->SetBoundsDirectCrossFade(bounds); + break; + } + bounds_change_animation_type_ = kAnimationNone; } else if (window_state->IsPinned() || window_state->IsTrustedPinned()) { // In pinned state, it should ignore the SetBounds from window manager // or user. } else { - delegate_->HandleBoundsRequest(window_state, - set_bounds_event->requested_bounds()); + delegate_->HandleBoundsRequest(window_state, bounds); } break; } @@ -167,11 +173,12 @@ bool ClientControlledState::EnterNextState( WindowState* window_state, - mojom::WindowStateType next_state_type) { + mojom::WindowStateType next_state_type, + BoundsChangeAnimationType animation_type) { // Do nothing if we're already in the same state. if (state_type_ == next_state_type) return false; - + bounds_change_animation_type_ = animation_type; mojom::WindowStateType previous_state_type = state_type_; state_type_ = next_state_type;
diff --git a/ash/wm/client_controlled_state.h b/ash/wm/client_controlled_state.h index ea88e02..9f57b14d 100644 --- a/ash/wm/client_controlled_state.h +++ b/ash/wm/client_controlled_state.h
@@ -51,6 +51,13 @@ // apply the bounds change to the window. void set_bounds_locally(bool set) { set_bounds_locally_ = set; } + // Type of animation type to be applied when changing bounds locally. + // TODO(oshima): Use transform animation for snapping. + enum BoundsChangeAnimationType { + kAnimationNone, + kAnimationCrossFade, + }; + // WindowState::State: void AttachState(WindowState* window_state, WindowState::State* previous_state) override; @@ -69,14 +76,19 @@ // Enters next state. This is used when the state moves from one to another // within the same desktop mode. Returns true if the state has changed, or // false otherwise. + // |animation_type| specifies the type of animation to be applied when + // bounds changes. bool EnterNextState(wm::WindowState* window_state, - mojom::WindowStateType next_state_type); + mojom::WindowStateType next_state_type, + BoundsChangeAnimationType animation_type); private: std::unique_ptr<Delegate> delegate_; bool set_bounds_locally_ = false; + BoundsChangeAnimationType bounds_change_animation_type_ = kAnimationNone; + DISALLOW_COPY_AND_ASSIGN(ClientControlledState); };
diff --git a/ash/wm/client_controlled_state_unittest.cc b/ash/wm/client_controlled_state_unittest.cc index 932242f..3302a1c 100644 --- a/ash/wm/client_controlled_state_unittest.cc +++ b/ash/wm/client_controlled_state_unittest.cc
@@ -119,7 +119,8 @@ EXPECT_EQ(mojom::WindowStateType::DEFAULT, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->new_state()); // Now enters the new state. - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMaximized()); // Bounds is controlled by client. EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -129,7 +130,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_FALSE(widget()->IsMaximized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); } @@ -140,7 +142,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::DEFAULT, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::MINIMIZED, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMinimized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -149,7 +152,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::MINIMIZED, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_FALSE(widget()->IsMinimized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -159,7 +163,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::MINIMIZED, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMinimized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -171,7 +176,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::MINIMIZED, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_FALSE(widget()->IsMinimized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); } @@ -182,7 +188,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::DEFAULT, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::FULLSCREEN, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsFullscreen()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -190,7 +197,8 @@ EXPECT_TRUE(widget()->IsFullscreen()); EXPECT_EQ(mojom::WindowStateType::FULLSCREEN, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_FALSE(widget()->IsFullscreen()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); } @@ -203,7 +211,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::DEFAULT, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMaximized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -212,7 +221,8 @@ EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::FULLSCREEN, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsFullscreen()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -220,7 +230,8 @@ EXPECT_TRUE(widget()->IsFullscreen()); EXPECT_EQ(mojom::WindowStateType::FULLSCREEN, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMaximized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); @@ -228,14 +239,16 @@ EXPECT_TRUE(widget()->IsMaximized()); EXPECT_EQ(mojom::WindowStateType::MAXIMIZED, delegate()->old_state()); EXPECT_EQ(mojom::WindowStateType::NORMAL, delegate()->new_state()); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_FALSE(widget()->IsMaximized()); EXPECT_EQ(kInitialBounds, widget()->GetWindowBoundsInScreen()); } TEST_F(ClientControlledStateTest, IgnoreWorkspace) { widget()->Maximize(); - state()->EnterNextState(window_state(), delegate()->new_state()); + state()->EnterNextState(window_state(), delegate()->new_state(), + ClientControlledState::kAnimationNone); EXPECT_TRUE(widget()->IsMaximized()); delegate()->reset();
diff --git a/chrome/browser/notifications/arc_application_notifier_controller_chromeos.cc b/chrome/browser/notifications/arc_application_notifier_controller_chromeos.cc index 8623f6b..0e54121b 100644 --- a/chrome/browser/notifications/arc_application_notifier_controller_chromeos.cc +++ b/chrome/browser/notifications/arc_application_notifier_controller_chromeos.cc
@@ -72,7 +72,7 @@ message_center::NotifierId::ARC_APPLICATION, app_id); auto ui_data = ash::mojom::NotifierUiData::New( notifier_id, base::UTF8ToUTF16(app->name), false, - app->notifications_enabled, icon->image_skia()); + app->notifications_enabled, false /* enforced */, icon->image_skia()); icons_.push_back(std::move(icon)); results.push_back(std::move(ui_data)); }
diff --git a/chrome/browser/notifications/extension_notifier_controller.cc b/chrome/browser/notifications/extension_notifier_controller.cc index e1475977..29dd7f7a 100644 --- a/chrome/browser/notifications/extension_notifier_controller.cc +++ b/chrome/browser/notifications/extension_notifier_controller.cc
@@ -66,7 +66,7 @@ notifier_id, base::UTF8ToUTF16(extension->name()), has_advanced_settings_button, notifier_state_tracker->IsNotifierEnabled(notifier_id), - gfx::ImageSkia())); + false /* enforced */, gfx::ImageSkia())); app_icon_loader_->FetchImage(extension->id()); }
diff --git a/chrome/browser/notifications/web_page_notifier_controller.cc b/chrome/browser/notifications/web_page_notifier_controller.cc index 62fa3e04..748b3c50 100644 --- a/chrome/browser/notifications/web_page_notifier_controller.cc +++ b/chrome/browser/notifications/web_page_notifier_controller.cc
@@ -46,9 +46,13 @@ message_center::NotifierId notifier_id(url); NotifierStateTracker* const notifier_state_tracker = NotifierStateTrackerFactory::GetForProfile(profile); + content_settings::SettingInfo info; + HostContentSettingsMapFactory::GetForProfile(profile)->GetWebsiteSetting( + url, GURL(), CONTENT_SETTINGS_TYPE_NOTIFICATIONS, std::string(), &info); notifiers.push_back(ash::mojom::NotifierUiData::New( - notifier_id, name, false, + notifier_id, name, false /* has_advanced_settings */, notifier_state_tracker->IsNotifierEnabled(notifier_id), + info.source == content_settings::SETTING_SOURCE_POLICY, gfx::ImageSkia())); patterns_[url_pattern] = iter->primary_pattern; // Note that favicon service obtains the favicon from history. This means
diff --git a/chrome/browser/resources/gaia_auth_host/authenticator.js b/chrome/browser/resources/gaia_auth_host/authenticator.js index f55f6593..c4bdad5 100644 --- a/chrome/browser/resources/gaia_auth_host/authenticator.js +++ b/chrome/browser/resources/gaia_auth_host/authenticator.js
@@ -336,7 +336,7 @@ url = appendParam(url, 'domain', data.enterpriseEnrollmentDomain); url = appendParam( url, 'continue', - data.gaiaUrl + 'o/oauth2/programmatic_auth?hl=' + data.hl + + data.gaiaUrl + 'programmatic_auth_chromeos?hl=' + data.hl + '&scope=https%3A%2F%2Fwww.google.com%2Faccounts%2FOAuthLogin&' + 'client_id=' + encodeURIComponent(data.clientId) + '&access_type=offline');
diff --git a/chrome/browser/resources/settings/device_page/display.html b/chrome/browser/resources/settings/device_page/display.html index b3e57b25..a97f335 100644 --- a/chrome/browser/resources/settings/device_page/display.html +++ b/chrome/browser/resources/settings/device_page/display.html
@@ -175,7 +175,8 @@ <button is="cr-link-row" icon-class="subpage-arrow" class="indented hr" id="overscan" label="$i18n{displayOverscanPageTitle}" - sub-label="$i18n{displayOverscanPageText}" on-tap="onOverscanTap_"> + sub-label="$i18n{displayOverscanPageText}" on-tap="onOverscanTap_" + hidden$="[[!showOverscanSetting_(selectedDisplay)]]"> </button> <settings-display-overscan-dialog id="displayOverscan"
diff --git a/chrome/browser/resources/settings/device_page/display.js b/chrome/browser/resources/settings/device_page/display.js index 1a35186..0d18d5e 100644 --- a/chrome/browser/resources/settings/device_page/display.js +++ b/chrome/browser/resources/settings/device_page/display.js
@@ -286,6 +286,16 @@ }, /** + * Returns true if the overscan setting should be shown for |display|. + * @param {!chrome.system.display.DisplayUnitInfo} display + * @return {boolean} + * @private + */ + showOverscanSetting_: function(display) { + return !display.isInternal; + }, + + /** * @param {!Array<!chrome.system.display.DisplayUnitInfo>} displays * @return {boolean} * @private
diff --git a/components/exo/client_controlled_shell_surface.cc b/components/exo/client_controlled_shell_surface.cc index a2814f62..1bdaeb0 100644 --- a/components/exo/client_controlled_shell_surface.cc +++ b/components/exo/client_controlled_shell_surface.cc
@@ -188,62 +188,24 @@ void ClientControlledShellSurface::SetMaximized() { TRACE_EVENT0("exo", "ClientControlledShellSurface::SetMaximized"); - - if (!widget_) - CreateShellSurfaceWidget(ui::SHOW_STATE_MAXIMIZED); - - ash::wm::WindowState* window_state = GetWindowState(); - if (IsPinned(window_state)) { - LOG(WARNING) << "Client changed the state to maximized while it's pinned"; - return; - } - - client_controlled_state_->EnterNextState( - window_state, ash::mojom::WindowStateType::MAXIMIZED); + pending_show_state_ = ui::SHOW_STATE_MAXIMIZED; } void ClientControlledShellSurface::SetMinimized() { TRACE_EVENT0("exo", "ClientControlledShellSurface::SetMinimized"); - - if (!widget_) - CreateShellSurfaceWidget(ui::SHOW_STATE_MINIMIZED); - - ash::wm::WindowState* window_state = GetWindowState(); - if (IsPinned(window_state)) { - LOG(WARNING) << "Client changed the state to minimized while it's pinned"; - return; - } - client_controlled_state_->EnterNextState( - window_state, ash::mojom::WindowStateType::MINIMIZED); + pending_show_state_ = ui::SHOW_STATE_MINIMIZED; } void ClientControlledShellSurface::SetRestored() { TRACE_EVENT0("exo", "ClientControlledShellSurface::SetRestored"); - if (!widget_) - return; - - ash::wm::WindowState* window_state = GetWindowState(); - client_controlled_state_->EnterNextState(window_state, - ash::mojom::WindowStateType::NORMAL); + pending_show_state_ = ui::SHOW_STATE_NORMAL; } void ClientControlledShellSurface::SetFullscreen(bool fullscreen) { TRACE_EVENT1("exo", "ClientControlledShellSurface::SetFullscreen", "fullscreen", fullscreen); - - if (!widget_) { - CreateShellSurfaceWidget(fullscreen ? ui::SHOW_STATE_FULLSCREEN - : ui::SHOW_STATE_NORMAL); - } - - ash::wm::WindowState* window_state = GetWindowState(); - if (IsPinned(window_state)) { - LOG(WARNING) << "Client changed the fullscreen state while it's pinned"; - return; - } - client_controlled_state_->EnterNextState( - window_state, fullscreen ? ash::mojom::WindowStateType::FULLSCREEN - : ash::mojom::WindowStateType::NORMAL); + pending_show_state_ = + fullscreen ? ui::SHOW_STATE_FULLSCREEN : ui::SHOW_STATE_NORMAL; } void ClientControlledShellSurface::SetPinned(ash::mojom::WindowPinType type) { @@ -335,34 +297,70 @@ // SurfaceDelegate overrides: void ClientControlledShellSurface::OnSurfaceCommit() { + if (!widget_) + CreateShellSurfaceWidget(pending_show_state_); + + if (widget_->GetNativeWindow()->GetProperty(aura::client::kShowStateKey) != + pending_show_state_) { + ash::wm::WindowState* window_state = GetWindowState(); + if (!IsPinned(window_state)) { + ash::mojom::WindowStateType next_window_state = + ash::mojom::WindowStateType::NORMAL; + ash::wm::ClientControlledState::BoundsChangeAnimationType animation_type = + ash::wm::ClientControlledState::kAnimationNone; + switch (pending_show_state_) { + case ui::SHOW_STATE_NORMAL: + if (widget_->IsMaximized() || widget_->IsFullscreen()) + animation_type = + ash::wm::ClientControlledState::kAnimationCrossFade; + break; + case ui::SHOW_STATE_MINIMIZED: + next_window_state = ash::mojom::WindowStateType::MINIMIZED; + break; + case ui::SHOW_STATE_MAXIMIZED: + animation_type = ash::wm::ClientControlledState::kAnimationCrossFade; + next_window_state = ash::mojom::WindowStateType::MAXIMIZED; + break; + case ui::SHOW_STATE_FULLSCREEN: + animation_type = ash::wm::ClientControlledState::kAnimationCrossFade; + next_window_state = ash::mojom::WindowStateType::FULLSCREEN; + break; + default: + break; + } + client_controlled_state_->EnterNextState(window_state, next_window_state, + animation_type); + } else { + VLOG(1) << "State change was requested while it is pinned"; + } + } + ShellSurfaceBase::OnSurfaceCommit(); + UpdateBackdrop(); + if (!geometry_changed_callback_.is_null()) geometry_changed_callback_.Run(GetVisibleBounds()); - if (widget_) { - // Apply new top inset height. - if (pending_top_inset_height_ != top_inset_height_) { - widget_->GetNativeWindow()->SetProperty(aura::client::kTopViewInset, - pending_top_inset_height_); - top_inset_height_ = pending_top_inset_height_; - } - - // Update surface scale. - if (pending_scale_ != scale_) { - gfx::Transform transform; - DCHECK_NE(pending_scale_, 0.0); - transform.Scale(1.0 / pending_scale_, 1.0 / pending_scale_); - host_window()->SetTransform(transform); - scale_ = pending_scale_; - } - - orientation_ = pending_orientation_; - if (expected_orientation_ == orientation_) - orientation_compositor_lock_.reset(); - } else { - orientation_compositor_lock_.reset(); + // Apply new top inset height. + if (pending_top_inset_height_ != top_inset_height_) { + widget_->GetNativeWindow()->SetProperty(aura::client::kTopViewInset, + pending_top_inset_height_); + top_inset_height_ = pending_top_inset_height_; } + + // Update surface scale. + if (pending_scale_ != scale_) { + gfx::Transform transform; + DCHECK_NE(pending_scale_, 0.0); + transform.Scale(1.0 / pending_scale_, 1.0 / pending_scale_); + host_window()->SetTransform(transform); + scale_ = pending_scale_; + } + + orientation_ = pending_orientation_; + if (expected_orientation_ == orientation_) + orientation_compositor_lock_.reset(); } //////////////////////////////////////////////////////////////////////////////// @@ -530,23 +528,10 @@ window_state->set_ignore_keyboard_bounds_change(true); } -void ClientControlledShellSurface::UpdateBackdrop() { - aura::Window* window = widget_->GetNativeWindow(); - bool enable_backdrop = widget_->IsFullscreen() || widget_->IsMaximized(); - if (window->GetProperty(aura::client::kHasBackdrop) != enable_backdrop) - window->SetProperty(aura::client::kHasBackdrop, enable_backdrop); -} - float ClientControlledShellSurface::GetScale() const { return scale_; } -bool ClientControlledShellSurface::CanAnimateWindowStateTransitions() const { - // TODO(domlaskowski): The configure callback does not yet support window - // state changes. See crbug.com/699746. - return false; -} - aura::Window* ClientControlledShellSurface::GetDragWindow() { return root_surface() ? root_surface()->window() : nullptr; } @@ -594,6 +579,19 @@ //////////////////////////////////////////////////////////////////////////////// // ClientControlledShellSurface, private: +void ClientControlledShellSurface::UpdateBackdrop() { + aura::Window* window = widget_->GetNativeWindow(); + const display::Display display = + display::Screen::GetScreen()->GetDisplayNearestWindow(window); + // TODO(oshima): We may want to use following condition: + // 1) the widget doesn't fill the screen/workspace and + // 2) the background opacity isn't 1.0f. + bool enable_backdrop = widget_->IsFullscreen() || widget_->IsMaximized(); + + if (window->GetProperty(aura::client::kHasBackdrop) != enable_backdrop) + window->SetProperty(aura::client::kHasBackdrop, enable_backdrop); +} + void ClientControlledShellSurface:: EnsureCompositorIsLockedForOrientationChange() { if (!orientation_compositor_lock_) {
diff --git a/components/exo/client_controlled_shell_surface.h b/components/exo/client_controlled_shell_surface.h index 2284ecc0..aff25d2 100644 --- a/components/exo/client_controlled_shell_surface.h +++ b/components/exo/client_controlled_shell_surface.h
@@ -142,9 +142,7 @@ void SetWidgetBounds(const gfx::Rect& bounds) override; gfx::Rect GetShadowBounds() const override; void InitializeWindowState(ash::wm::WindowState* window_state) override; - void UpdateBackdrop() override; float GetScale() const override; - bool CanAnimateWindowStateTransitions() const override; aura::Window* GetDragWindow() override; std::unique_ptr<ash::WindowResizer> CreateWindowResizer( aura::Window* window, @@ -153,6 +151,8 @@ gfx::Point GetWidgetOrigin() const override; gfx::Point GetSurfaceOrigin() const override; + void UpdateBackdrop(); + // Lock the compositor if it's not already locked, or extends the // lock timeout if it's already locked. // TODO(reveman): Remove this when using configure callbacks for orientation. @@ -179,6 +179,8 @@ ash::wm::ClientControlledState* client_controlled_state_ = nullptr; + ui::WindowShowState pending_show_state_ = ui::SHOW_STATE_NORMAL; + std::unique_ptr<ui::CompositorLock> orientation_compositor_lock_; DISALLOW_COPY_AND_ASSIGN(ClientControlledShellSurface);
diff --git a/components/exo/client_controlled_shell_surface_unittest.cc b/components/exo/client_controlled_shell_surface_unittest.cc index 3748798c..fb30f29b5 100644 --- a/components/exo/client_controlled_shell_surface_unittest.cc +++ b/components/exo/client_controlled_shell_surface_unittest.cc
@@ -394,6 +394,7 @@ auto shell_surface = exo_test_helper()->CreateClientControlledShellSurface(surface.get()); shell_surface->SetMaximized(); + surface->Commit(); views::Widget* widget = shell_surface->GetWidget(); aura::Window* window = widget->GetNativeWindow(); @@ -501,7 +502,7 @@ surface->Commit(); EXPECT_FALSE(HasBackdrop()); shell_surface->SetMaximized(); - EXPECT_TRUE(HasBackdrop()); + EXPECT_FALSE(HasBackdrop()); surface->Commit(); EXPECT_TRUE(HasBackdrop()); EXPECT_TRUE(shell_surface->GetWidget()->IsMaximized()); @@ -532,8 +533,13 @@ EXPECT_FALSE(HasBackdrop()); // Note: Remove contents to avoid issues with maximize animations in tests. shell_surface->SetMaximized(); + EXPECT_FALSE(HasBackdrop()); + surface->Commit(); EXPECT_TRUE(HasBackdrop()); + shell_surface->SetRestored(); + EXPECT_TRUE(HasBackdrop()); + surface->Commit(); EXPECT_FALSE(HasBackdrop()); } @@ -568,7 +574,9 @@ surface->Attach(buffer.get()); surface->Commit(); EXPECT_FALSE(HasBackdrop()); + shell_surface->SetMaximized(); + surface->Commit(); EXPECT_TRUE(HasBackdrop()); ash::wm::WMEvent event(ash::wm::WM_EVENT_TOGGLE_FULLSCREEN); @@ -576,7 +584,6 @@ // Enter fullscreen mode. ash::wm::GetWindowState(window)->OnWMEvent(&event); - EXPECT_TRUE(HasBackdrop()); // Leave fullscreen mode.
diff --git a/components/exo/shell_surface.cc b/components/exo/shell_surface.cc index 10f7534..1bcfad83 100644 --- a/components/exo/shell_surface.cc +++ b/components/exo/shell_surface.cc
@@ -11,12 +11,57 @@ #include "base/logging.h" #include "base/strings/utf_string_conversions.h" #include "components/exo/wm_helper.h" +#include "ui/aura/client/aura_constants.h" #include "ui/aura/client/cursor_client.h" #include "ui/aura/window.h" #include "ui/views/widget/widget.h" #include "ui/wm/core/window_util.h" namespace exo { +namespace { + +// Maximum amount of time to wait for contents after a change to maximize, +// fullscreen or pinned state. +constexpr int kMaximizedOrFullscreenOrPinnedLockTimeoutMs = 100; + +} // namespace + +//////////////////////////////////////////////////////////////////////////////// +// ShellSurface, ScopedAnimationsDisabled: + +// Helper class used to temporarily disable animations. Restores the +// animations disabled property when instance is destroyed. +class ShellSurface::ScopedAnimationsDisabled { + public: + explicit ScopedAnimationsDisabled(ShellSurface* shell_surface); + ~ScopedAnimationsDisabled(); + + private: + ShellSurface* const shell_surface_; + bool saved_animations_disabled_ = false; + + DISALLOW_COPY_AND_ASSIGN(ScopedAnimationsDisabled); +}; + +ShellSurface::ScopedAnimationsDisabled::ScopedAnimationsDisabled( + ShellSurface* shell_surface) + : shell_surface_(shell_surface) { + if (shell_surface_->widget_) { + aura::Window* window = shell_surface_->widget_->GetNativeWindow(); + saved_animations_disabled_ = + window->GetProperty(aura::client::kAnimationsDisabledKey); + window->SetProperty(aura::client::kAnimationsDisabledKey, true); + } +} + +ShellSurface::ScopedAnimationsDisabled::~ScopedAnimationsDisabled() { + if (shell_surface_->widget_) { + aura::Window* window = shell_surface_->widget_->GetNativeWindow(); + DCHECK_EQ(window->GetProperty(aura::client::kAnimationsDisabledKey), true); + window->SetProperty(aura::client::kAnimationsDisabledKey, + saved_animations_disabled_); + } +} //////////////////////////////////////////////////////////////////////////////// // ShellSurface, public: @@ -36,6 +81,8 @@ ash::kShellWindowId_DefaultContainer) {} ShellSurface::~ShellSurface() { + if (widget_) + ash::wm::GetWindowState(widget_->GetNativeWindow())->RemoveObserver(this); } void ShellSurface::SetParent(ShellSurface* parent) { @@ -110,9 +157,63 @@ } void ShellSurface::InitializeWindowState(ash::wm::WindowState* window_state) { + window_state->AddObserver(this); window_state->set_allow_set_bounds_direct(false); widget_->set_movement_disabled(movement_disabled_); window_state->set_ignore_keyboard_bounds_change(movement_disabled_); } +//////////////////////////////////////////////////////////////////////////////// +// ash::wm::WindowStateObserver overrides: + +void ShellSurface::OnPreWindowStateTypeChange( + ash::wm::WindowState* window_state, + ash::mojom::WindowStateType old_type) { + ash::mojom::WindowStateType new_type = window_state->GetStateType(); + if (old_type == ash::mojom::WindowStateType::MINIMIZED || + new_type == ash::mojom::WindowStateType::MINIMIZED) { + return; + } + + if (ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(old_type) || + ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(new_type)) { + if (!widget_) + return; + // When transitioning in/out of maximized or fullscreen mode, we need to + // make sure we have a configure callback before we allow the default + // cross-fade animations. The configure callback provides a mechanism for + // the client to inform us that a frame has taken the state change into + // account, and without this cross-fade animations are unreliable. + if (!configure_callback_.is_null()) { + // Give client a chance to produce a frame that takes state change into + // account by acquiring a compositor lock. + ui::Compositor* compositor = + widget_->GetNativeWindow()->layer()->GetCompositor(); + configure_compositor_lock_ = compositor->GetCompositorLock( + nullptr, base::TimeDelta::FromMilliseconds( + kMaximizedOrFullscreenOrPinnedLockTimeoutMs)); + } else { + scoped_animations_disabled_ = + std::make_unique<ScopedAnimationsDisabled>(this); + } + } +} + +void ShellSurface::OnPostWindowStateTypeChange( + ash::wm::WindowState* window_state, + ash::mojom::WindowStateType old_type) { + ash::mojom::WindowStateType new_type = window_state->GetStateType(); + if (ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(new_type)) { + Configure(); + } + + if (widget_) { + UpdateWidgetBounds(); + UpdateShadow(); + } + + // Re-enable animations if they were disabled in pre state change handler. + scoped_animations_disabled_.reset(); +} + } // namespace exo
diff --git a/components/exo/shell_surface.h b/components/exo/shell_surface.h index e638990b..589e27b 100644 --- a/components/exo/shell_surface.h +++ b/components/exo/shell_surface.h
@@ -5,6 +5,7 @@ #ifndef COMPONENTS_EXO_SHELL_SURFACE_H_ #define COMPONENTS_EXO_SHELL_SURFACE_H_ +#include "ash/wm/window_state_observer.h" #include "base/macros.h" #include "components/exo/shell_surface_base.h" @@ -13,7 +14,8 @@ // This class implements toplevel surface for which position and state are // managed by the shell. -class ShellSurface : public ShellSurfaceBase { +class ShellSurface : public ShellSurfaceBase, + public ash::wm::WindowStateObserver { public: // The |origin| is the initial position in screen coordinates. The position // specified as part of the geometry is relative to the shell surface. @@ -52,7 +54,19 @@ // Overridden from ShellSurfaceBase: void InitializeWindowState(ash::wm::WindowState* window_state) override; + // Overridden from ash::wm::WindowStateObserver: + void OnPreWindowStateTypeChange( + ash::wm::WindowState* window_state, + ash::mojom::WindowStateType old_type) override; + void OnPostWindowStateTypeChange( + ash::wm::WindowState* window_state, + ash::mojom::WindowStateType old_type) override; + private: + class ScopedAnimationsDisabled; + + std::unique_ptr<ScopedAnimationsDisabled> scoped_animations_disabled_; + DISALLOW_COPY_AND_ASSIGN(ShellSurface); };
diff --git a/components/exo/shell_surface_base.cc b/components/exo/shell_surface_base.cc index 201718a..b431039 100644 --- a/components/exo/shell_surface_base.cc +++ b/components/exo/shell_surface_base.cc
@@ -56,10 +56,6 @@ // Application Id set by the client. DEFINE_OWNED_UI_CLASS_PROPERTY_KEY(std::string, kApplicationIdKey, nullptr); -// Maximum amount of time to wait for contents after a change to maximize, -// fullscreen or pinned state. -constexpr int kMaximizedOrFullscreenOrPinnedLockTimeoutMs = 100; - // The accelerator keys used to close ShellSurfaces. const struct { ui::KeyboardCode keycode; @@ -243,20 +239,6 @@ std::unique_ptr<ui::CompositorLock> compositor_lock; }; -// Helper class used to temporarily disable animations. Restores the -// animations disabled property when instance is destroyed. -class ShellSurfaceBase::ScopedAnimationsDisabled { - public: - explicit ScopedAnimationsDisabled(ShellSurfaceBase* shell_surface); - ~ScopedAnimationsDisabled(); - - private: - ShellSurfaceBase* const shell_surface_; - bool saved_animations_disabled_ = false; - - DISALLOW_COPY_AND_ASSIGN(ScopedAnimationsDisabled); -}; - //////////////////////////////////////////////////////////////////////////////// // ShellSurfaceBase, Config: @@ -297,29 +279,6 @@ } //////////////////////////////////////////////////////////////////////////////// -// ShellSurfaceBase, ScopedAnimationsDisabled: - -ShellSurfaceBase::ScopedAnimationsDisabled::ScopedAnimationsDisabled( - ShellSurfaceBase* shell_surface) - : shell_surface_(shell_surface) { - if (shell_surface_->widget_) { - aura::Window* window = shell_surface_->widget_->GetNativeWindow(); - saved_animations_disabled_ = - window->GetProperty(aura::client::kAnimationsDisabledKey); - window->SetProperty(aura::client::kAnimationsDisabledKey, true); - } -} - -ShellSurfaceBase::ScopedAnimationsDisabled::~ScopedAnimationsDisabled() { - if (shell_surface_->widget_) { - aura::Window* window = shell_surface_->widget_->GetNativeWindow(); - DCHECK_EQ(window->GetProperty(aura::client::kAnimationsDisabledKey), true); - window->SetProperty(aura::client::kAnimationsDisabledKey, - saved_animations_disabled_); - } -} - -//////////////////////////////////////////////////////////////////////////////// // ShellSurfaceBase, public: ShellSurfaceBase::ShellSurfaceBase(Surface* surface, @@ -347,7 +306,6 @@ // casuing the configure callback to be called. WMHelper::GetInstance()->RemoveActivationObserver(this); if (widget_) { - ash::wm::GetWindowState(widget_->GetNativeWindow())->RemoveObserver(this); widget_->GetNativeWindow()->RemoveObserver(this); // Remove transient children so they are not automatically destroyed. for (auto* child : wm::GetTransientChildren(widget_->GetNativeWindow())) @@ -825,54 +783,6 @@ } //////////////////////////////////////////////////////////////////////////////// -// ash::wm::WindowStateObserver overrides: - -void ShellSurfaceBase::OnPreWindowStateTypeChange( - ash::wm::WindowState* window_state, - ash::mojom::WindowStateType old_type) { - ash::mojom::WindowStateType new_type = window_state->GetStateType(); - if (old_type == ash::mojom::WindowStateType::MINIMIZED || - new_type == ash::mojom::WindowStateType::MINIMIZED) { - return; - } - - if (ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(old_type) || - ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(new_type)) { - if (CanAnimateWindowStateTransitions()) { - if (!widget_) - return; - // Give client a chance to produce a frame that takes state change into - // account by acquiring a compositor lock. - ui::Compositor* compositor = - widget_->GetNativeWindow()->layer()->GetCompositor(); - configure_compositor_lock_ = compositor->GetCompositorLock( - nullptr, base::TimeDelta::FromMilliseconds( - kMaximizedOrFullscreenOrPinnedLockTimeoutMs)); - } else { - scoped_animations_disabled_.reset(new ScopedAnimationsDisabled(this)); - } - } -} - -void ShellSurfaceBase::OnPostWindowStateTypeChange( - ash::wm::WindowState* window_state, - ash::mojom::WindowStateType old_type) { - ash::mojom::WindowStateType new_type = window_state->GetStateType(); - if (ash::IsMaximizedOrFullscreenOrPinnedWindowStateType(new_type)) { - Configure(); - } - - if (widget_) { - UpdateWidgetBounds(); - UpdateShadow(); - UpdateBackdrop(); - } - - // Re-enable animations if they were disabled in pre state change handler. - scoped_animations_disabled_.reset(); -} - -//////////////////////////////////////////////////////////////////////////////// // aura::WindowObserver overrides: void ShellSurfaceBase::OnWindowBoundsChanged(aura::Window* window, @@ -1097,8 +1007,6 @@ // Start tracking changes to window bounds and window state. window->AddObserver(this); ash::wm::WindowState* window_state = ash::wm::GetWindowState(window); - window_state->AddObserver(this); - InitializeWindowState(window_state); // AutoHide shelf in fullscreen state. @@ -1243,8 +1151,6 @@ shadow_bounds_changed_ = false; - UpdateBackdrop(); - aura::Window* window = widget_->GetNativeWindow(); if (!shadow_bounds_) { @@ -1295,21 +1201,10 @@ //////////////////////////////////////////////////////////////////////////////// // ShellSurfaceBase, private: -void ShellSurfaceBase::UpdateBackdrop() {} - float ShellSurfaceBase::GetScale() const { return 1.f; } -bool ShellSurfaceBase::CanAnimateWindowStateTransitions() const { - // When transitioning in/out of maximized or fullscreen mode, we need to - // make sure we have a configure callback before we allow the default - // cross-fade animations. The configure callback provides a mechanism for - // the client to inform us that a frame has taken the state change into - // account, and without this cross-fade animations are unreliable. - return !configure_callback_.is_null(); -} - aura::Window* ShellSurfaceBase::GetDragWindow() { return movement_disabled_ ? nullptr : widget_->GetNativeWindow(); }
diff --git a/components/exo/shell_surface_base.h b/components/exo/shell_surface_base.h index d39e310..d0860fb0 100644 --- a/components/exo/shell_surface_base.h +++ b/components/exo/shell_surface_base.h
@@ -10,14 +10,13 @@ #include <string> #include "ash/display/window_tree_host_manager.h" -#include "ash/wm/window_state_observer.h" +#include "ash/public/interfaces/window_state_type.mojom.h" #include "base/containers/circular_deque.h" #include "base/macros.h" #include "base/optional.h" #include "base/strings/string16.h" #include "components/exo/surface_observer.h" #include "components/exo/surface_tree_host.h" - #include "ui/aura/window_observer.h" #include "ui/base/hit_test.h" #include "ui/compositor/compositor_lock.h" @@ -30,6 +29,9 @@ namespace ash { class WindowResizer; +namespace wm { +class WindowState; +} } namespace base { @@ -53,7 +55,6 @@ public aura::WindowObserver, public views::WidgetDelegate, public views::View, - public ash::wm::WindowStateObserver, public wm::ActivationChangeObserver { public: // The |origin| is the initial position in screen coordinates. The position @@ -182,14 +183,6 @@ gfx::Size GetMinimumSize() const override; gfx::Size GetMaximumSize() const override; - // Overridden from ash::wm::WindowStateObserver: - void OnPreWindowStateTypeChange( - ash::wm::WindowState* window_state, - ash::mojom::WindowStateType old_type) override; - void OnPostWindowStateTypeChange( - ash::wm::WindowState* window_state, - ash::mojom::WindowStateType old_type) override; - // Overridden from aura::WindowObserver: void OnWindowBoundsChanged(aura::Window* window, const gfx::Rect& old_bounds, @@ -293,25 +286,19 @@ bool shadow_bounds_changed_ = false; std::unique_ptr<ash::WindowResizer> resizer_; base::string16 title_; + std::unique_ptr<ui::CompositorLock> configure_compositor_lock_; + ConfigureCallback configure_callback_; private: struct Config; - class ScopedAnimationsDisabled; - // Called on widget creation to initialize its window state. // TODO(reveman): Remove virtual functions below to avoid FBC problem. virtual void InitializeWindowState(ash::wm::WindowState* window_state) = 0; - // Updates the backdrop of the sshell surface based on the window state. - virtual void UpdateBackdrop(); - // Returns the scale of the surface tree relative to the shell surface. virtual float GetScale() const; - // Returns whether window state transitions should be animated. - virtual bool CanAnimateWindowStateTransitions() const; - // Returns the window that has capture during dragging. virtual aura::Window* GetDragWindow(); @@ -340,11 +327,8 @@ gfx::Rect pending_geometry_; base::RepeatingClosure close_callback_; base::OnceClosure surface_destroyed_callback_; - ConfigureCallback configure_callback_; ScopedConfigure* scoped_configure_ = nullptr; - std::unique_ptr<ui::CompositorLock> configure_compositor_lock_; base::circular_deque<std::unique_ptr<Config>> pending_configs_; - std::unique_ptr<ScopedAnimationsDisabled> scoped_animations_disabled_; bool system_modal_ = false; bool non_system_modal_window_was_active_ = false; gfx::ImageSkia icon_;
diff --git a/components/exo/test/test_client_controlled_state_delegate.cc b/components/exo/test/test_client_controlled_state_delegate.cc index cc3e897..d229677 100644 --- a/components/exo/test/test_client_controlled_state_delegate.cc +++ b/components/exo/test/test_client_controlled_state_delegate.cc
@@ -4,8 +4,10 @@ #include "components/exo/test/test_client_controlled_state_delegate.h" +#include "ash/public/interfaces/window_state_type.mojom.h" #include "ash/wm/window_state.h" #include "components/exo/client_controlled_shell_surface.h" +#include "ui/views/widget/widget.h" namespace exo { namespace test { @@ -18,10 +20,29 @@ void TestClientControlledStateDelegate::HandleWindowStateRequest( ash::wm::WindowState* window_state, ash::mojom::WindowStateType next_state) { - ash::wm::ClientControlledState* state_impl = - static_cast<ash::wm::ClientControlledState*>( - ash::wm::WindowState::TestApi::GetStateImpl(window_state)); - state_impl->EnterNextState(window_state, next_state); + views::Widget* widget = + views::Widget::GetWidgetForNativeWindow(window_state->window()); + ClientControlledShellSurface* shell_surface = + static_cast<ClientControlledShellSurface*>(widget->widget_delegate()); + switch (next_state) { + case ash::mojom::WindowStateType::NORMAL: + case ash::mojom::WindowStateType::DEFAULT: + shell_surface->SetRestored(); + break; + case ash::mojom::WindowStateType::MINIMIZED: + shell_surface->SetMinimized(); + break; + case ash::mojom::WindowStateType::MAXIMIZED: + shell_surface->SetMaximized(); + break; + case ash::mojom::WindowStateType::FULLSCREEN: + shell_surface->SetFullscreen(true); + break; + default: + NOTIMPLEMENTED(); + break; + } + shell_surface->OnSurfaceCommit(); } void TestClientControlledStateDelegate::HandleBoundsRequest(
diff --git a/components/offline_pages/core/BUILD.gn b/components/offline_pages/core/BUILD.gn index 4520d9ba..1721d916 100644 --- a/components/offline_pages/core/BUILD.gn +++ b/components/offline_pages/core/BUILD.gn
@@ -35,6 +35,8 @@ "model/mark_page_accessed_task.h", "model/offline_page_model_taskified.cc", "model/offline_page_model_taskified.h", + "model/offline_page_model_utils.cc", + "model/offline_page_model_utils.h", "model/persistent_pages_consistency_check_task.cc", "model/persistent_pages_consistency_check_task.h", "model/temporary_pages_consistency_check_task.cc", @@ -146,6 +148,7 @@ "model/get_pages_task_unittest.cc", "model/mark_page_accessed_task_unittest.cc", "model/offline_page_model_taskified_unittest.cc", + "model/offline_page_model_utils_unittest.cc", "model/persistent_pages_consistency_check_task_unittest.cc", "model/temporary_pages_consistency_check_task_unittest.cc", "offline_event_logger_unittest.cc",
diff --git a/components/offline_pages/core/client_namespace_constants.h b/components/offline_pages/core/client_namespace_constants.h index b25186d..ce98319f 100644 --- a/components/offline_pages/core/client_namespace_constants.h +++ b/components/offline_pages/core/client_namespace_constants.h
@@ -9,8 +9,13 @@ namespace offline_pages { +// Currently used for fallbacks like tests. +extern const char kDefaultNamespace[]; + // Any changes to these well-known namespaces should also be reflected in -// OfflinePagesNamespace (histograms.xml) for consistency. +// OfflinePagesNamespaceEnumeration (histograms.xml) for consistency. +// New namespaces should be put at the end of this list and a corresponding +// enum value should be added in OfflinePagesNamespaceEnumeration. extern const char kBookmarkNamespace[]; extern const char kLastNNamespace[]; extern const char kAsyncNamespace[]; @@ -20,8 +25,25 @@ extern const char kSuggestedArticlesNamespace[]; extern const char kBrowserActionsNamespace[]; -// Currently used for fallbacks like tests. -extern const char kDefaultNamespace[]; +// Enum of namespaces used by metric collection. +// See OfflinePagesNamespaceEnumeration in enums.xml for histogram usages. +// Changes to this enum should be in sync with the changes to the namespace +// constants above. +enum class OfflinePagesNamespaceEnumeration { + DEFAULT = 0, + BOOKMARK = 1, + LAST_N = 2, + ASYNC_LOADING = 3, + CUSTOM_TABS = 4, + DOWNLOAD = 5, + NTP_SUGGESTION = 6, + SUGGESTED_ARTICLES = 7, + BROWSER_ACTIONS = 8, + // NOTE: always keep this entry at the end. Add new result types only + // immediately above this line. Make sure to update the corresponding + // histogram enum accordingly. + RESULT_COUNT, +}; } // namespace offline_pages
diff --git a/components/offline_pages/core/model/mark_page_accessed_task.cc b/components/offline_pages/core/model/mark_page_accessed_task.cc index d380a75..d807145 100644 --- a/components/offline_pages/core/model/mark_page_accessed_task.cc +++ b/components/offline_pages/core/model/mark_page_accessed_task.cc
@@ -5,29 +5,57 @@ #include "components/offline_pages/core/model/mark_page_accessed_task.h" #include "base/bind.h" +#include "base/metrics/histogram_macros.h" +#include "components/offline_pages/core/client_namespace_constants.h" +#include "components/offline_pages/core/model/offline_page_model_utils.h" #include "components/offline_pages/core/offline_page_metadata_store_sql.h" #include "components/offline_pages/core/offline_store_utils.h" #include "sql/connection.h" #include "sql/statement.h" +#include "sql/transaction.h" namespace offline_pages { namespace { +#define OFFLINE_PAGES_TABLE_NAME "offlinepages_v1" + +void ReportAccessHistogram(int64_t offline_id, sql::Connection* db) { + const char kSql[] = "SELECT client_namespace FROM " OFFLINE_PAGES_TABLE_NAME + " WHERE offline_id = ?"; + sql::Statement statement(db->GetCachedStatement(SQL_FROM_HERE, kSql)); + statement.BindInt64(0, offline_id); + if (statement.Step()) { + UMA_HISTOGRAM_ENUMERATION( + "OfflinePages.AccessPageCount", + model_utils::ToNamespaceEnum(statement.ColumnString(0)), + OfflinePagesNamespaceEnumeration::RESULT_COUNT); + } +} + bool MarkPageAccessedSync(const base::Time& last_access_time, int64_t offline_id, sql::Connection* db) { if (!db) return false; + sql::Transaction transaction(db); + if (!transaction.Begin()) + return false; + + ReportAccessHistogram(offline_id, db); + const char kSql[] = - "UPDATE OR IGNORE offlinepages_v1" + "UPDATE OR IGNORE " OFFLINE_PAGES_TABLE_NAME " SET last_access_time = ?, access_count = access_count + 1" " WHERE offline_id = ?"; sql::Statement statement(db->GetCachedStatement(SQL_FROM_HERE, kSql)); statement.BindInt64(0, store_utils::ToDatabaseTime(last_access_time)); statement.BindInt64(1, offline_id); - return statement.Run(); + if (!statement.Run()) + return false; + + return transaction.Commit(); } } // namespace
diff --git a/components/offline_pages/core/model/mark_page_accessed_task_unittest.cc b/components/offline_pages/core/model/mark_page_accessed_task_unittest.cc index 216d38b7..ea8bbe4c 100644 --- a/components/offline_pages/core/model/mark_page_accessed_task_unittest.cc +++ b/components/offline_pages/core/model/mark_page_accessed_task_unittest.cc
@@ -8,9 +8,11 @@ #include "base/memory/ptr_util.h" #include "base/memory/ref_counted.h" +#include "base/test/histogram_tester.h" #include "base/test/test_mock_time_task_runner.h" #include "base/threading/thread_task_runner_handle.h" #include "base/time/time.h" +#include "components/offline_pages/core/model/offline_page_model_utils.h" #include "components/offline_pages/core/offline_page_metadata_store_test_util.h" #include "components/offline_pages/core/test_task_runner.h" #include "testing/gtest/include/gtest/gtest.h" @@ -39,12 +41,14 @@ return &store_test_util_; } TestTaskRunner* runner() { return &runner_; } + base::HistogramTester* histogram_tester() { return histogram_tester_.get(); } private: scoped_refptr<base::TestMockTimeTaskRunner> task_runner_; base::ThreadTaskRunnerHandle task_runner_handle_; OfflinePageMetadataStoreTestUtil store_test_util_; TestTaskRunner runner_; + std::unique_ptr<base::HistogramTester> histogram_tester_; }; MarkPageAccessedTaskTest::MarkPageAccessedTaskTest() @@ -57,6 +61,7 @@ void MarkPageAccessedTaskTest::SetUp() { store_test_util_.BuildStoreInMemory(); + histogram_tester_ = base::MakeUnique<base::HistogramTester>(); } void MarkPageAccessedTaskTest::TearDown() { @@ -79,6 +84,10 @@ EXPECT_EQ(kTestFileSize, offline_page->file_size); EXPECT_EQ(1, offline_page->access_count); EXPECT_EQ(current_time, offline_page->last_access_time); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.AccessPageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId.name_space)), + 1); } TEST_F(MarkPageAccessedTaskTest, MarkPageAccessedTwice) { @@ -98,6 +107,10 @@ EXPECT_EQ(kTestFileSize, offline_page->file_size); EXPECT_EQ(1, offline_page->access_count); EXPECT_EQ(current_time, offline_page->last_access_time); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.AccessPageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId.name_space)), + 1); task = base::MakeUnique<MarkPageAccessedTask>(store(), kTestOfflineId, base::Time::Now()); @@ -107,6 +120,10 @@ EXPECT_EQ(kTestOfflineId, offline_page->offline_id); EXPECT_EQ(2, offline_page->access_count); EXPECT_LT(current_time, offline_page->last_access_time); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.AccessPageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId.name_space)), + 2); } } // namespace offline_pages
diff --git a/components/offline_pages/core/model/offline_page_item_generator.h b/components/offline_pages/core/model/offline_page_item_generator.h index 4163047..f40fe520 100644 --- a/components/offline_pages/core/model/offline_page_item_generator.h +++ b/components/offline_pages/core/model/offline_page_item_generator.h
@@ -7,6 +7,7 @@ #include <string> +#include "components/offline_pages/core/client_namespace_constants.h" #include "components/offline_pages/core/offline_page_item.h" class GURL; @@ -34,7 +35,7 @@ void SetArchiveDirectory(const base::FilePath& archive_dir); private: - std::string namespace_; + std::string namespace_ = kDefaultNamespace; std::string id_; std::string request_origin_; GURL url_;
diff --git a/components/offline_pages/core/model/offline_page_model_taskified.cc b/components/offline_pages/core/model/offline_page_model_taskified.cc index 5e0ef32..54ebac3 100644 --- a/components/offline_pages/core/model/offline_page_model_taskified.cc +++ b/components/offline_pages/core/model/offline_page_model_taskified.cc
@@ -9,18 +9,21 @@ #include "base/bind.h" #include "base/location.h" +#include "base/metrics/histogram_functions.h" #include "base/metrics/histogram_macros.h" #include "base/strings/string16.h" #include "base/threading/thread_task_runner_handle.h" #include "base/time/default_clock.h" #include "base/time/time.h" #include "components/offline_pages/core/archive_manager.h" +#include "components/offline_pages/core/client_namespace_constants.h" #include "components/offline_pages/core/model/add_page_task.h" #include "components/offline_pages/core/model/clear_legacy_temporary_pages_task.h" #include "components/offline_pages/core/model/create_archive_task.h" #include "components/offline_pages/core/model/delete_page_task.h" #include "components/offline_pages/core/model/get_pages_task.h" #include "components/offline_pages/core/model/mark_page_accessed_task.h" +#include "components/offline_pages/core/model/offline_page_model_utils.h" #include "components/offline_pages/core/model/persistent_pages_consistency_check_task.h" #include "components/offline_pages/core/model/temporary_pages_consistency_check_task.h" #include "components/offline_pages/core/offline_page_metadata_store.h" @@ -275,6 +278,10 @@ const SavePageCallback& callback, SavePageResult result, const OfflinePageItem& page) { + UMA_HISTOGRAM_ENUMERATION( + "OfflinePages.SavePageCount", + model_utils::ToNamespaceEnum(page.client_id.name_space), + OfflinePagesNamespaceEnumeration::RESULT_COUNT); if (result == SavePageResult::ARCHIVE_CREATION_FAILED) CreateArchivesDirectoryIfNeeded(); if (!callback.is_null()) @@ -354,6 +361,10 @@ DeletePageResult result, const std::vector<OfflinePageModel::DeletedPageInfo>& infos) { for (const auto& info : infos) { + UMA_HISTOGRAM_ENUMERATION( + "OfflinePages.DeletePageCount", + model_utils::ToNamespaceEnum(info.client_id.name_space), + OfflinePagesNamespaceEnumeration::RESULT_COUNT); for (Observer& observer : observers_) observer.OfflinePageDeleted(info); }
diff --git a/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc b/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc index 6977e3ab..5f0efbc 100644 --- a/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc +++ b/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc
@@ -11,12 +11,14 @@ #include "base/files/file_util.h" #include "base/files/scoped_temp_dir.h" #include "base/strings/utf_string_conversions.h" +#include "base/test/histogram_tester.h" #include "base/test/mock_callback.h" #include "base/test/test_mock_time_task_runner.h" #include "base/threading/thread_task_runner_handle.h" #include "build/build_config.h" #include "components/offline_pages/core/client_namespace_constants.h" #include "components/offline_pages/core/model/offline_page_item_generator.h" +#include "components/offline_pages/core/model/offline_page_model_utils.h" #include "components/offline_pages/core/model/offline_page_test_util.h" #include "components/offline_pages/core/offline_page_item.h" #include "components/offline_pages/core/offline_page_metadata_store_sql.h" @@ -125,6 +127,7 @@ } OfflinePageItemGenerator* page_generator() { return &generator_; } TaskQueue* task_queue() { return &model_->task_queue_; } + base::HistogramTester* histogram_tester() { return histogram_tester_.get(); } const base::FilePath& temporary_dir_path() { return temporary_dir_.GetPath(); } @@ -151,6 +154,7 @@ std::unique_ptr<OfflinePageModelTaskified> model_; OfflinePageMetadataStoreTestUtil store_test_util_; OfflinePageItemGenerator generator_; + std::unique_ptr<base::HistogramTester> histogram_tester_; base::ScopedTempDir temporary_dir_; base::ScopedTempDir persistent_dir_; @@ -179,6 +183,7 @@ } void OfflinePageModelTaskifiedTest::TearDown() { + CheckTaskQueueIdle(); store_test_util_.DeleteStore(); if (temporary_dir_.IsValid()) { if (!temporary_dir_.Delete()) @@ -189,7 +194,6 @@ DLOG(ERROR) << "persistent_dir not created"; } EXPECT_EQ(0UL, model_->pending_archivers_.size()); - CheckTaskQueueIdle(); model_->RemoveObserver(this); model_.reset(); PumpLoop(); @@ -208,6 +212,7 @@ store_test_util()->ReleaseStore(), std::move(archive_manager), base::ThreadTaskRunnerHandle::Get(), task_runner_->GetMockClock()); model_->AddObserver(this); + histogram_tester_ = base::MakeUnique<base::HistogramTester>(); ResetResults(); EXPECT_EQ(0UL, model_->pending_archivers_.size()); } @@ -315,6 +320,12 @@ EXPECT_EQ(kTestUrl2, saved_page_ptr->original_url); EXPECT_EQ("", saved_page_ptr->request_origin); EXPECT_EQ(kTestDigest, saved_page_ptr->digest); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(saved_page_ptr->client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageSuccessfulWithSameOriginalUrl) { @@ -333,6 +344,12 @@ EXPECT_EQ(kTestUrl, saved_page_ptr->url); // The original URL should be empty. EXPECT_TRUE(saved_page_ptr->original_url.is_empty()); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(saved_page_ptr->client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageSuccessfulWithRequestOrigin) { @@ -356,6 +373,12 @@ EXPECT_EQ(kTestTitle, saved_page_ptr->title); EXPECT_EQ(kTestUrl2, saved_page_ptr->original_url); EXPECT_EQ(kTestRequestOrigin, saved_page_ptr->request_origin); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(saved_page_ptr->client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageOfflineArchiverCancelled) { @@ -363,6 +386,11 @@ SavePageWithExpectedResult(kTestUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::move(archiver), SavePageResult::CANCELLED); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageOfflineArchiverDeviceFull) { @@ -370,6 +398,11 @@ SavePageWithExpectedResult(kTestUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::move(archiver), SavePageResult::DEVICE_FULL); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, @@ -379,6 +412,11 @@ SavePageWithExpectedResult(kTestUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::move(archiver), SavePageResult::CONTENT_UNAVAILABLE); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageOfflineCreationFailed) { @@ -387,6 +425,11 @@ SavePageWithExpectedResult(kTestUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::move(archiver), SavePageResult::ARCHIVE_CREATION_FAILED); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageOfflineArchiverReturnedWrongUrl) { @@ -395,6 +438,11 @@ SavePageWithExpectedResult(kTestUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::move(archiver), SavePageResult::ARCHIVE_CREATION_FAILED); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } // This test is disabled since it's lacking the ability of mocking store failure @@ -407,6 +455,11 @@ SavePageWithExpectedResult( kFileUrl, kTestClientId1, kTestUrl2, kEmptyRequestOrigin, std::unique_ptr<OfflinePageTestArchiver>(), SavePageResult::SKIPPED); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, SavePageOfflineArchiverTwoPages) { @@ -442,6 +495,11 @@ EXPECT_EQ(1LL, store_test_util()->GetPageCount()); base::FilePath saved_file_path1 = last_path_created_by_archiver(); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId2.name_space)), + 1); + ResetResults(); delayed_archiver_ptr->CompleteCreateArchive(); @@ -468,6 +526,11 @@ EXPECT_EQ(kTestClientId1, saved_page_ptr2->client_id); EXPECT_EQ(saved_file_path2, saved_page_ptr2->file_path); EXPECT_EQ(kTestFileSize, saved_page_ptr2->file_size); + + histogram_tester()->ExpectUniqueSample( + "OfflinePages.SavePageCount", + static_cast<int>(model_utils::ToNamespaceEnum(kTestClientId1.name_space)), + 2); } TEST_F(OfflinePageModelTaskifiedTest, AddPage) { @@ -499,6 +562,10 @@ store_test_util()->GetPageByOfflineId(page.offline_id); ASSERT_TRUE(accessed_page_ptr); EXPECT_EQ(1LL, accessed_page_ptr->access_count); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.AccessPageCount", + static_cast<int>(model_utils::ToNamespaceEnum(page.client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, GetAllPagesWhenStoreEmpty) { @@ -558,7 +625,11 @@ EXPECT_EQ(last_deleted_page_info().offline_id, page1.offline_id); EXPECT_EQ(1UL, test_util::GetFileCountInDirectory(temporary_dir_path())); EXPECT_EQ(1LL, store_test_util()->GetPageCount()); - CheckTaskQueueIdle(); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.DeletePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(page1.client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, DeletePagesByUrlPredicate) { @@ -590,7 +661,11 @@ EXPECT_EQ(last_deleted_page_info().offline_id, page1.offline_id); EXPECT_EQ(1UL, test_util::GetFileCountInDirectory(temporary_dir_path())); EXPECT_EQ(1LL, store_test_util()->GetPageCount()); - CheckTaskQueueIdle(); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.DeletePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(page1.client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, GetPageByOfflineId) { @@ -778,7 +853,11 @@ EXPECT_EQ(last_deleted_page_info().client_id, page1.client_id); EXPECT_EQ(1UL, test_util::GetFileCountInDirectory(temporary_dir_path())); EXPECT_EQ(1LL, store_test_util()->GetPageCount()); - CheckTaskQueueIdle(); + histogram_tester()->ExpectUniqueSample( + "OfflinePages.DeletePageCount", + static_cast<int>( + model_utils::ToNamespaceEnum(page1.client_id.name_space)), + 1); } TEST_F(OfflinePageModelTaskifiedTest, GetPagesByNamespace) {
diff --git a/components/offline_pages/core/model/offline_page_model_utils.cc b/components/offline_pages/core/model/offline_page_model_utils.cc new file mode 100644 index 0000000..06b91b312 --- /dev/null +++ b/components/offline_pages/core/model/offline_page_model_utils.cc
@@ -0,0 +1,43 @@ +// Copyright 2017 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "components/offline_pages/core/model/offline_page_model_utils.h" + +#include <string> + +#include "base/logging.h" +#include "components/offline_pages/core/client_namespace_constants.h" + +namespace offline_pages { + +namespace model_utils { + +OfflinePagesNamespaceEnumeration ToNamespaceEnum( + const std::string& name_space) { + if (name_space == kDefaultNamespace) + return OfflinePagesNamespaceEnumeration::DEFAULT; + else if (name_space == kBookmarkNamespace) + return OfflinePagesNamespaceEnumeration::BOOKMARK; + else if (name_space == kLastNNamespace) + return OfflinePagesNamespaceEnumeration::LAST_N; + else if (name_space == kAsyncNamespace) + return OfflinePagesNamespaceEnumeration::ASYNC_LOADING; + else if (name_space == kCCTNamespace) + return OfflinePagesNamespaceEnumeration::CUSTOM_TABS; + else if (name_space == kDownloadNamespace) + return OfflinePagesNamespaceEnumeration::DOWNLOAD; + else if (name_space == kNTPSuggestionsNamespace) + return OfflinePagesNamespaceEnumeration::NTP_SUGGESTION; + else if (name_space == kSuggestedArticlesNamespace) + return OfflinePagesNamespaceEnumeration::SUGGESTED_ARTICLES; + else if (name_space == kBrowserActionsNamespace) + return OfflinePagesNamespaceEnumeration::BROWSER_ACTIONS; + + NOTREACHED(); + return OfflinePagesNamespaceEnumeration::DEFAULT; +} + +} // namespace model_utils + +} // namespace offline_pages
diff --git a/components/offline_pages/core/model/offline_page_model_utils.h b/components/offline_pages/core/model/offline_page_model_utils.h new file mode 100644 index 0000000..c161717a --- /dev/null +++ b/components/offline_pages/core/model/offline_page_model_utils.h
@@ -0,0 +1,22 @@ +// Copyright 2017 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef COMPONENTS_OFFLINE_PAGES_CORE_MODEL_OFFLINE_PAGE_MODEL_UTILS_H_ +#define COMPONENTS_OFFLINE_PAGES_CORE_MODEL_OFFLINE_PAGE_MODEL_UTILS_H_ + +#include <string> + +namespace offline_pages { + +enum class OfflinePagesNamespaceEnumeration; + +namespace model_utils { + +OfflinePagesNamespaceEnumeration ToNamespaceEnum(const std::string& name_space); + +} // namespace model_utils + +} // namespace offline_pages + +#endif // COMPONENTS_OFFLINE_PAGES_CORE_MODEL_OFFLINE_PAGE_MODEL_UTILS_H_
diff --git a/components/offline_pages/core/model/offline_page_model_utils_unittest.cc b/components/offline_pages/core/model/offline_page_model_utils_unittest.cc new file mode 100644 index 0000000..b5b306b --- /dev/null +++ b/components/offline_pages/core/model/offline_page_model_utils_unittest.cc
@@ -0,0 +1,33 @@ +// Copyright 2017 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "components/offline_pages/core/model/offline_page_model_utils.h" + +#include "components/offline_pages/core/client_namespace_constants.h" +#include "testing/gtest/include/gtest/gtest.h" + +namespace offline_pages { + +TEST(OfflinePageModelUtilsTest, ToNamespaceEnum) { + EXPECT_EQ(model_utils::ToNamespaceEnum(kDefaultNamespace), + OfflinePagesNamespaceEnumeration::DEFAULT); + EXPECT_EQ(model_utils::ToNamespaceEnum(kBookmarkNamespace), + OfflinePagesNamespaceEnumeration::BOOKMARK); + EXPECT_EQ(model_utils::ToNamespaceEnum(kLastNNamespace), + OfflinePagesNamespaceEnumeration::LAST_N); + EXPECT_EQ(model_utils::ToNamespaceEnum(kAsyncNamespace), + OfflinePagesNamespaceEnumeration::ASYNC_LOADING); + EXPECT_EQ(model_utils::ToNamespaceEnum(kCCTNamespace), + OfflinePagesNamespaceEnumeration::CUSTOM_TABS); + EXPECT_EQ(model_utils::ToNamespaceEnum(kDownloadNamespace), + OfflinePagesNamespaceEnumeration::DOWNLOAD); + EXPECT_EQ(model_utils::ToNamespaceEnum(kNTPSuggestionsNamespace), + OfflinePagesNamespaceEnumeration::NTP_SUGGESTION); + EXPECT_EQ(model_utils::ToNamespaceEnum(kSuggestedArticlesNamespace), + OfflinePagesNamespaceEnumeration::SUGGESTED_ARTICLES); + EXPECT_EQ(model_utils::ToNamespaceEnum(kBrowserActionsNamespace), + OfflinePagesNamespaceEnumeration::BROWSER_ACTIONS); +} + +} // namespace offline_pages
diff --git a/content/browser/compositor/viz_process_transport_factory.cc b/content/browser/compositor/viz_process_transport_factory.cc index e436753..7cb397c 100644 --- a/content/browser/compositor/viz_process_transport_factory.cc +++ b/content/browser/compositor/viz_process_transport_factory.cc
@@ -305,7 +305,11 @@ } viz::FrameSinkManagerImpl* VizProcessTransportFactory::GetFrameSinkManager() { - // FrameSinkManagerImpl is in the gpu process, not the browser process. + // When running with viz there is no FrameSinkManagerImpl in the browser + // process. FrameSinkManagerImpl runs in the GPU process instead. Anything in + // the browser process that relies FrameSinkManagerImpl or SurfaceManager + // internal state needs to change. See https://crbug.com/787097 and + // https://crbug.com/760181 for more context. NOTREACHED(); return nullptr; }
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc index 345c71d..26eae43d 100644 --- a/content/browser/renderer_host/render_widget_host_impl.cc +++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -1048,8 +1048,6 @@ void RenderWidgetHostImpl::StartHangMonitorTimeout( base::TimeDelta delay, blink::WebInputEvent::Type event_type) { - if (hang_start_time_.is_null()) - hang_start_time_ = TimeTicks::Now(); if (!hang_monitor_timeout_) return; if (!hang_monitor_timeout_->IsRunning()) @@ -1059,12 +1057,8 @@ } void RenderWidgetHostImpl::RestartHangMonitorTimeoutIfNecessary() { - if (in_flight_event_count_ > 0 && !is_hidden_) { - LogHangMonitorUnresponsive(); - hang_start_time_ = TimeTicks::Now(); - if (hang_monitor_timeout_) - hang_monitor_timeout_->Restart(hung_renderer_delay_); - } + if (hang_monitor_timeout_ && in_flight_event_count_ > 0 && !is_hidden_) + hang_monitor_timeout_->Restart(hung_renderer_delay_); } bool RenderWidgetHostImpl::IsCurrentlyUnresponsive() const { @@ -1072,20 +1066,11 @@ } void RenderWidgetHostImpl::StopHangMonitorTimeout() { - LogHangMonitorUnresponsive(); - hang_start_time_ = TimeTicks(); if (hang_monitor_timeout_) hang_monitor_timeout_->Stop(); RendererIsResponsive(); } -void RenderWidgetHostImpl::LogHangMonitorUnresponsive() { - if (!hang_start_time_.is_null()) { - UMA_HISTOGRAM_TIMES("MPArch.RWH_HangMonitorUnresponsive", - TimeTicks::Now() - hang_start_time_); - } -} - void RenderWidgetHostImpl::StartNewContentRenderingTimeout( uint32_t next_source_id) { current_content_source_id_ = next_source_id;
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h index 3462e19..fae871cd 100644 --- a/content/browser/renderer_host/render_widget_host_impl.h +++ b/content/browser/renderer_host/render_widget_host_impl.h
@@ -789,9 +789,6 @@ // responsive. void StopHangMonitorTimeout(); - // Used for UMA logging how long the renderer was unresponsive. - void LogHangMonitorUnresponsive(); - // Once both the frame and its swap messages arrive, we call this method to // process the messages. Virtual for tests. virtual void ProcessSwapMessages(std::vector<IPC::Message> messages); @@ -901,9 +898,6 @@ // operation to finish. base::TimeTicks repaint_start_time_; - // Used for UMA histogram logging to measure how long the renderer is hanging. - base::TimeTicks hang_start_time_; - // Set to true if we shouldn't send input events from the render widget. bool ignore_input_events_;
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.h b/content/browser/renderer_host/render_widget_host_view_mac.h index 336e898..67c8e279 100644 --- a/content/browser/renderer_host/render_widget_host_view_mac.h +++ b/content/browser/renderer_host/render_widget_host_view_mac.h
@@ -629,6 +629,17 @@ // The size associated with the current LocalSurfaceId if any. gfx::Size last_size_; + enum class RepaintState { + // No repaint in progress. + None, + + // Synchronously waiting for a new frame. + Paused, + + // Screen updates are disabled while a new frame is swapped in. + ScreenUpdatesDisabled, + } repaint_state_ = RepaintState::None; + // The last device scale factor associated with the current // LocalSurfaceId if any. float last_device_scale_factor_ = 0.f;
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm index 844929f..56a534d 100644 --- a/content/browser/renderer_host/render_widget_host_view_mac.mm +++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
@@ -1435,6 +1435,16 @@ viz::mojom::HitTestRegionListPtr hit_test_region_list) { TRACE_EVENT0("browser", "RenderWidgetHostViewMac::OnSwapCompositorFrame"); + if (repaint_state_ == RepaintState::Paused) { + gfx::Size frame_size = gfx::ConvertSizeToDIP( + frame.metadata.device_scale_factor, frame.size_in_pixels()); + gfx::Size view_size = gfx::Size(cocoa_view_.bounds.size); + if (frame_size == view_size || render_widget_host_->auto_resize_enabled()) { + NSDisableScreenUpdates(); + repaint_state_ = RepaintState::ScreenUpdatesDisabled; + } + } + last_frame_root_background_color_ = frame.metadata.root_background_color; last_scroll_offset_ = frame.metadata.root_scroll_offset; @@ -1754,7 +1764,11 @@ return; // Wait for a frame of the right size to come in. + repaint_state_ = RepaintState::Paused; render_widget_host_->PauseForPendingResizeOrRepaints(); + if (repaint_state_ == RepaintState::ScreenUpdatesDisabled) + NSEnableScreenUpdates(); + repaint_state_ = RepaintState::None; } ////////////////////////////////////////////////////////////////////////////////
diff --git a/content/renderer/media/gpu/rtc_video_encoder_factory.cc b/content/renderer/media/gpu/rtc_video_encoder_factory.cc index b60583f..ff170a1f 100644 --- a/content/renderer/media/gpu/rtc_video_encoder_factory.cc +++ b/content/renderer/media/gpu/rtc_video_encoder_factory.cc
@@ -7,6 +7,7 @@ #include <memory> #include "base/command_line.h" +#include "build/build_config.h" #include "content/public/common/content_features.h" #include "content/public/common/content_switches.h" #include "content/public/common/feature_h264_with_openh264_ffmpeg.h" @@ -46,7 +47,15 @@ webrtc::H264::Profile h264_profile; switch (profile.profile) { case media::H264PROFILE_BASELINE: +#if defined(OS_ANDROID) + // Force HW H264 on Android to be CBP for most compatibility, since: + // - Only HW H264 is available on Android at present. + // - MediaCodec only advise BP, which works same as CBP in most cases. + // - Some peers only expect CBP in negotiation. + h264_profile = webrtc::H264::kProfileConstrainedBaseline; +#else h264_profile = webrtc::H264::kProfileBaseline; +#endif break; case media::H264PROFILE_MAIN: h264_profile = webrtc::H264::kProfileMain;
diff --git a/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-object-preview-expected.txt b/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-object-preview-expected.txt index 031dfec..0fd20318 100644 --- a/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-object-preview-expected.txt +++ b/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-object-preview-expected.txt
@@ -1,66 +1,66 @@ Tests that console produces instant previews for arrays and objects. console-object-preview.js:10 Mutating object in a loop console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:14 {a: 0, b: 0, c: 0} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children -console-object-preview.js:14 {a: 0, b: 0, c: 1} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children -console-object-preview.js:14 {a: 0, b: 0, c: 2} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:14 {a: 0, b: 0, c: 0} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:14 {a: 0, b: 0, c: 1} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:14 {a: 0, b: 0, c: 2} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children console-object-preview.js:17 Mutating array in a loop console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:21 (3) [0, 0, 0] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children -console-object-preview.js:21 (3) [0, 0, 1] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children -console-object-preview.js:21 (3) [0, 0, 2] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children +console-object-preview.js:21 (3) [0, 0, 0] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children +console-object-preview.js:21 (3) [0, 0, 1] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children +console-object-preview.js:21 (3) [0, 0, 2] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children console-object-preview.js:24 Object with many properties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:29 {property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:29 {property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children console-object-preview.js:31 Array with many properties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:36 (2) [0, 1, property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:36 (2) [0, 1, property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children console-object-preview.js:38 Array with gaps and overflow console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:43 (5733) [32: 0, 89: 1, 146: 2, 203: 3, 260: 4, 317: 5, 374: 6, 431: 7, 488: 8, 545: 9, 602: 10, 659: 11, 716: 12, 773: 13, 830: 14, 887: 15, 944: 16, 1001: 17, 1058: 18, 1115: 19, 1172: 20, 1229: 21, 1286: 22, 1343: 23, 1400: 24, 1457: 25, 1514: 26, 1571: 27, 1628: 28, 1685: 29, 1742: 30, 1799: 31, 1856: 32, 1913: 33, 1970: 34, 2027: 35, 2084: 36, 2141: 37, 2198: 38, 2255: 39, 2312: 40, 2369: 41, 2426: 42, 2483: 43, 2540: 44, 2597: 45, 2654: 46, 2711: 47, 2768: 48, 2825: 49, 2882: 50, 2939: 51, 2996: 52, 3053: 53, 3110: 54, 3167: 55, 3224: 56, 3281: 57, 3338: 58, 3395: 59, 3452: 60, 3509: 61, 3566: 62, 3623: 63, 3680: 64, 3737: 65, 3794: 66, 3851: 67, 3908: 68, 3965: 69, 4022: 70, 4079: 71, 4136: 72, 4193: 73, 4250: 74, 4307: 75, 4364: 76, 4421: 77, 4478: 78, 4535: 79, 4592: 80, 4649: 81, 4706: 82, 4763: 83, 4820: 84, 4877: 85, 4934: 86, 4991: 87, 5048: 88, 5105: 89, 5162: 90, 5219: 91, 5276: 92, 5333: 93, 5390: 94, 5447: 95, 5504: 96, 5561: 97, 5618: 98, 5675: 99, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:43 (5733) [32: 0, 89: 1, 146: 2, 203: 3, 260: 4, 317: 5, 374: 6, 431: 7, 488: 8, 545: 9, 602: 10, 659: 11, 716: 12, 773: 13, 830: 14, 887: 15, 944: 16, 1001: 17, 1058: 18, 1115: 19, 1172: 20, 1229: 21, 1286: 22, 1343: 23, 1400: 24, 1457: 25, 1514: 26, 1571: 27, 1628: 28, 1685: 29, 1742: 30, 1799: 31, 1856: 32, 1913: 33, 1970: 34, 2027: 35, 2084: 36, 2141: 37, 2198: 38, 2255: 39, 2312: 40, 2369: 41, 2426: 42, 2483: 43, 2540: 44, 2597: 45, 2654: 46, 2711: 47, 2768: 48, 2825: 49, 2882: 50, 2939: 51, 2996: 52, 3053: 53, 3110: 54, 3167: 55, 3224: 56, 3281: 57, 3338: 58, 3395: 59, 3452: 60, 3509: 61, 3566: 62, 3623: 63, 3680: 64, 3737: 65, 3794: 66, 3851: 67, 3908: 68, 3965: 69, 4022: 70, 4079: 71, 4136: 72, 4193: 73, 4250: 74, 4307: 75, 4364: 76, 4421: 77, 4478: 78, 4535: 79, 4592: 80, 4649: 81, 4706: 82, 4763: 83, 4820: 84, 4877: 85, 4934: 86, 4991: 87, 5048: 88, 5105: 89, 5162: 90, 5219: 91, 5276: 92, 5333: 93, 5390: 94, 5447: 95, 5504: 96, 5561: 97, 5618: 98, 5675: 99, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children console-object-preview.js:45 Array with gaps without overflow console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:50 (5619) [empty × 32, 0, empty × 56, 1, empty × 56, 2, empty × 56, 3, empty × 56, 4, empty × 56, 5, empty × 56, 6, empty × 56, 7, empty × 56, 8, empty × 56, 9, empty × 56, 10, empty × 56, 11, empty × 56, 12, empty × 56, 13, empty × 56, 14, empty × 56, 15, empty × 56, 16, empty × 56, 17, empty × 56, 18, empty × 56, 19, empty × 56, 20, empty × 56, 21, empty × 56, 22, empty × 56, 23, empty × 56, 24, empty × 56, 25, empty × 56, 26, empty × 56, 27, empty × 56, 28, empty × 56, 29, empty × 56, 30, empty × 56, 31, empty × 56, 32, empty × 56, 33, empty × 56, 34, empty × 56, 35, empty × 56, 36, empty × 56, 37, empty × 56, 38, empty × 56, 39, empty × 56, 40, empty × 56, 41, empty × 56, 42, empty × 56, 43, empty × 56, 44, empty × 56, 45, empty × 56, 46, empty × 56, 47, empty × 56, 48, empty × 56, 49, empty × 56, 50, empty × 56, 51, empty × 56, 52, empty × 56, 53, empty × 56, 54, empty × 56, 55, empty × 56, 56, empty × 56, 57, empty × 56, 58, empty × 56, 59, empty × 56, 60, empty × 56, 61, empty console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-state-note info-note > children +console-object-preview.js:50 (5619) [empty × 32, 0, empty × 56, 1, empty × 56, 2, empty × 56, 3, empty × 56, 4, empty × 56, 5, empty × 56, 6, empty × 56, 7, empty × 56, 8, empty × 56, 9, empty × 56, 10, empty × 56, 11, empty × 56, 12, empty × 56, 13, empty × 56, 14, empty × 56, 15, empty × 56, 16, empty × 56, 17, empty × 56, 18, empty × 56, 19, empty × 56, 20, empty × 56, 21, empty × 56, 22, empty × 56, 23, empty × 56, 24, empty × 56, 25, empty × 56, 26, empty × 56, 27, empty × 56, 28, empty × 56, 29, empty × 56, 30, empty × 56, 31, empty × 56, 32, empty × 56, 33, empty × 56, 34, empty × 56, 35, empty × 56, 36, empty × 56, 37, empty × 56, 38, empty × 56, 39, empty × 56, 40, empty × 56, 41, empty × 56, 42, empty × 56, 43, empty × 56, 44, empty × 56, 45, empty × 56, 46, empty × 56, 47, empty × 56, 48, empty × 56, 49, empty × 56, 50, empty × 56, 51, empty × 56, 52, empty × 56, 53, empty × 56, 54, empty × 56, 55, empty × 56, 56, empty × 56, 57, empty × 56, 58, empty × 56, 59, empty × 56, 60, empty × 56, 61, empty console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-state-note info-note > children console-object-preview.js:52 Object with proto console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:55 {d: 1} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > object-state-note info-note > children +console-object-preview.js:55 {d: 1} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > object-state-note info-note > children console-object-preview.js:57 Sparse array console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:60 (150) [empty × 50, 50, empty × 99] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-undefined > object-value-number > object-value-undefined > object-state-note info-note > children +console-object-preview.js:60 (150) [empty × 50, 50, empty × 99] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-undefined > object-value-number > object-value-undefined > object-state-note info-note > children console-object-preview.js:62 Dense array with indexes and propeties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:68 (150) [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-state-note info-note > children +console-object-preview.js:68 (150) [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, …] console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-state-note info-note > children console-object-preview.js:70 Object with properties containing whitespaces console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:77 {" a b ": " a b ", c d: "c d", "": "", " ": " ", "a↵↵b↵c": "a↵↵b↵c"} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > object-state-note info-note > children +console-object-preview.js:77 {" a b ": " a b ", c d: "c d", "": "", " ": " ", "a↵↵b↵c": "a↵↵b↵c"} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > object-state-note info-note > children console-object-preview.js:79 Object with a document.all property console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:80 {all: HTMLAllCollection(4)} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-array > object-state-note info-note > children +console-object-preview.js:80 {all: HTMLAllCollection(4)} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-array > object-state-note info-note > children console-object-preview.js:82 Object with special numbers console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:84 {nan: NaN, posInf: Infinity, negInf: -Infinity, negZero: -0} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:84 {nan: NaN, posInf: Infinity, negInf: -Infinity, negZero: -0} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children console-object-preview.js:86 Object with exactly 5 properties: expected to be lossless console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:87 {a: 1, b: 2, c: 3, d: 4, e: 5} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children -console-object-preview.js:89 {null: null, undef: undefined, regexp: /^[regexp]$/g, bool: false} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-null > name > object-value-undefined > name > object-value-regexp > name > object-value-boolean > object-state-note info-note > children +console-object-preview.js:87 {a: 1, b: 2, c: 3, d: 4, e: 5} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-object-preview.js:89 {null: null, undef: undefined, regexp: /^[regexp]$/g, bool: false} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-null > name > object-value-undefined > name > object-value-regexp > name > object-value-boolean > object-state-note info-note > children Expanded all messages console-object-preview.js:10 Mutating object in a loop console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:14 {a: 0, b: 0, c: 0}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children -console-object-preview.js:14 {a: 0, b: 0, c: 1}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children -console-object-preview.js:14 {a: 0, b: 0, c: 2}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:14 {a: 0, b: 0, c: 0}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:14 {a: 0, b: 0, c: 1}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:14 {a: 0, b: 0, c: 2}a: 0b: 0c: 2__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:17 Mutating array in a loop console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:21 (3) [0, 0, 0]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children -console-object-preview.js:21 (3) [0, 0, 1]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children -console-object-preview.js:21 (3) [0, 0, 2]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:21 (3) [0, 0, 0]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:21 (3) [0, 0, 1]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:21 (3) [0, 0, 2]0: 01: 02: 2length: 3__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:24 Object with many properties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:29 {property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …}property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:29 {property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …}property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:31 Array with many properties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:36 (2) [0, 1, property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …]0: 01: 1property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9length: 2__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:36 (2) [0, 1, property_0: 0, property_1: 1, property_2: 2, property_3: 3, property_4: 4, …]0: 01: 1property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9length: 2__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:38 Array with gaps and overflow console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:43 (5733) [32: 0, 89: 1, 146: 2, 203: 3, 260: 4, 317: 5, 374: 6, 431: 7, 488: 8, 545: 9, 602: 10, 659: 11, 716: 12, 773: 13, 830: 14, 887: 15, 944: 16, 1001: 17, 1058: 18, 1115: 19, 1172: 20, 1229: 21, 1286: 22, 1343: 23, 1400: 24, 1457: 25, 1514: 26, 1571: 27, 1628: 28, 1685: 29, 1742: 30, 1799: 31, 1856: 32, 1913: 33, 1970: 34, 2027: 35, 2084: 36, 2141: 37, 2198: 38, 2255: 39, 2312: 40, 2369: 41, 2426: 42, 2483: 43, 2540: 44, 2597: 45, 2654: 46, 2711: 47, 2768: 48, 2825: 49, 2882: 50, 2939: 51, 2996: 52, 3053: 53, 3110: 54, 3167: 55, 3224: 56, 3281: 57, 3338: 58, 3395: 59, 3452: 60, 3509: 61, 3566: 62, 3623: 63, 3680: 64, 3737: 65, 3794: 66, 3851: 67, 3908: 68, 3965: 69, 4022: 70, 4079: 71, 4136: 72, 4193: 73, 4250: 74, 4307: 75, 4364: 76, 4421: 77, 4478: 78, 4535: 79, 4592: 80, 4649: 81, 4706: 82, 4763: 83, 4820: 84, 4877: 85, 4934: 86, 4991: 87, 5048: 88, 5105: 89, 5162: 90, 5219: 91, 5276: 92, 5333: 93, 5390: 94, 5447: 95, 5504: 96, 5561: 97, 5618: 98, 5675: 99, …][32 … 5675]573 console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent object-properties-section-name > selection fill > tree-element-title > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:43 (5733) [32: 0, 89: 1, 146: 2, 203: 3, 260: 4, 317: 5, 374: 6, 431: 7, 488: 8, 545: 9, 602: 10, 659: 11, 716: 12, 773: 13, 830: 14, 887: 15, 944: 16, 1001: 17, 1058: 18, 1115: 19, 1172: 20, 1229: 21, 1286: 22, 1343: 23, 1400: 24, 1457: 25, 1514: 26, 1571: 27, 1628: 28, 1685: 29, 1742: 30, 1799: 31, 1856: 32, 1913: 33, 1970: 34, 2027: 35, 2084: 36, 2141: 37, 2198: 38, 2255: 39, 2312: 40, 2369: 41, 2426: 42, 2483: 43, 2540: 44, 2597: 45, 2654: 46, 2711: 47, 2768: 48, 2825: 49, 2882: 50, 2939: 51, 2996: 52, 3053: 53, 3110: 54, 3167: 55, 3224: 56, 3281: 57, 3338: 58, 3395: 59, 3452: 60, 3509: 61, 3566: 62, 3623: 63, 3680: 64, 3737: 65, 3794: 66, 3851: 67, 3908: 68, 3965: 69, 4022: 70, 4079: 71, 4136: 72, 4193: 73, 4250: 74, 4307: 75, 4364: 76, 4421: 77, 4478: 78, 4535: 79, 4592: 80, 4649: 81, 4706: 82, 4763: 83, 4820: 84, 4877: 85, 4934: 86, 4991: 87, 5048: 88, 5105: 89, 5162: 90, 5219: 91, 5276: 92, 5333: 93, 5390: 94, 5447: 95, 5504: 96, 5561: 97, 5618: 98, 5675: 99, …][32 … 5675]573 console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent object-properties-section-name > selection fill > tree-element-title > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:45 Array with gaps without overflow console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:50 (5619) [empty × 32, 0, empty × 56, 1, empty × 56, 2, empty × 56, 3, empty × 56, 4, empty × 56, 5, empty × 56, 6, empty × 56, 7, empty × 56, 8, empty × 56, 9, empty × 56, 10, empty × 56, 11, empty × 56, 12, empty × 56, 13, empty × 56, 14, empty × 56, 15, empty × 56, 16, empty × 56, 17, empty × 56, 18, empty × 56, 19, empty × 56, 20, empty × 56, 21, empty × 56, 22, empty × 56, 23, empty × 56, 24, empty × 56, 25, empty × 56, 26, empty × 56, 27, empty × 56, 28, empty × 56, 29, empty × 56, 30, empty × 56, 31, empty × 56, 32, empty × 56, 33, empty × 56, 34, empty × 56, 35, empty × 56, 36, empty × 56, 37, empty × 56, 38, empty × 56, 39, empty × 56, 40, empty × 56, 41, empty × 56, 42, empty × 56, 43, empty × 56, 44, empty × 56, 45, empty × 56, 46, empty × 56, 47, empty × 56, 48, empty × 56, 49, empty × 56, 50, empty × 56, 51, empty × 56, 52, empty × 56, 53, empty × 56, 54, empty × 56, 55, empty × 56, 56, empty × 56, 57, empty × 56, 58, empty × 56, 59, empty × 56, 60, empty × 56, 61, empty console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:50 (5619) [empty × 32, 0, empty × 56, 1, empty × 56, 2, empty × 56, 3, empty × 56, 4, empty × 56, 5, empty × 56, 6, empty × 56, 7, empty × 56, 8, empty × 56, 9, empty × 56, 10, empty × 56, 11, empty × 56, 12, empty × 56, 13, empty × 56, 14, empty × 56, 15, empty × 56, 16, empty × 56, 17, empty × 56, 18, empty × 56, 19, empty × 56, 20, empty × 56, 21, empty × 56, 22, empty × 56, 23, empty × 56, 24, empty × 56, 25, empty × 56, 26, empty × 56, 27, empty × 56, 28, empty × 56, 29, empty × 56, 30, empty × 56, 31, empty × 56, 32, empty × 56, 33, empty × 56, 34, empty × 56, 35, empty × 56, 36, empty × 56, 37, empty × 56, 38, empty × 56, 39, empty × 56, 40, empty × 56, 41, empty × 56, 42, empty × 56, 43, empty × 56, 44, empty × 56, 45, empty × 56, 46, empty × 56, 47, empty × 56, 48, empty × 56, 49, empty × 56, 50, empty × 56, 51, empty × 56, 52, empty × 56, 53, empty × 56, 54, empty × 56, 55, empty × 56, 56, empty × 56, 57, empty × 56, 58, empty × 56, 59, empty × 56, 60, empty × 56, 61, empty console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-value-undefined > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:52 Object with proto console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:55 {d: 1}d: 1__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:55 {d: 1}d: 1__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:57 Sparse array console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:60 (150) [empty × 50, 50, empty × 99]50: 50length: 150__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-undefined > object-value-number > object-value-undefined > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:60 (150) [empty × 50, 50, empty × 99]50: 50length: 150__proto__: Array(0) console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-undefined > object-value-number > object-value-undefined > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:62 Dense array with indexes and propeties console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:68 (150) [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, …][0 … 99][100 … 149]property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9property_10: 10property_11: 11property_12: 12property_13: 13property_14: 14property_15: 15property_16: 16property_17: 17property_18: 18property_19: 19property_20: 20property_21: 21property_22: 22property_23: 23property_24: 24property_25: 25property_26: 26property_27: 27property_28: 28property_29: 29property_30: 30property_31: 31property_32: 32property_33: 33property_34: 34property_35: 35property_36: 36property_37: 37property_38: 38property_39: console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > parent object-properties-section-name > selection fill > tree-element-title > children > parent object-properties-section-name > selection fill > tree-element-title > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children +console-object-preview.js:68 (150) [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, …][0 … 99][100 … 149]property_0: 0property_1: 1property_2: 2property_3: 3property_4: 4property_5: 5property_6: 6property_7: 7property_8: 8property_9: 9property_10: 10property_11: 11property_12: 12property_13: 13property_14: 14property_15: 15property_16: 16property_17: 17property_18: 18property_19: 19property_20: 20property_21: 21property_22: 22property_23: 23property_24: 24property_25: 25property_26: 26property_27: 27property_28: 28property_29: 29property_30: 30property_31: 31property_32: 32property_33: 33property_34: 34property_35: 35property_36: 36property_37: 37property_38: 38property_39: console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-array source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-value-number > object-state-note info-note > children expanded > parent object-properties-section-name > selection fill > tree-element-title > children > parent object-properties-section-name > selection fill > tree-element-title > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-array value > children console-object-preview.js:70 Object with properties containing whitespaces console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:77 {" a b ": " a b ", c d: "c d", "": "", " ": " ", "a↵↵b↵c": "a↵↵b↵c"}"": """ ": " "" a b ": " a b ""a↵↵b↵c": "a↵↵b↵c"c d: "c d"__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:77 {" a b ": " a b ", c d: "c d", "": "", " ": " ", "a↵↵b↵c": "a↵↵b↵c"}"": """ ": " "" a b ": " a b ""a↵↵b↵c": "a↵↵b↵c"c d: "c d"__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > name > object-value-string > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > selection fill > name > object-properties-section-separator > object-value-string value > object-value-string-quote > object-value-string-quote > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:79 Object with a document.all property console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:80 {all: HTMLAllCollection(4)}all: HTMLAllCollection(4) [html, head, base, body]__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-array > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-array value > object-description > object-properties-preview source-code > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:80 {all: HTMLAllCollection(4)}all: HTMLAllCollection(4) [html, head, base, body]__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-array > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-array value > object-description > object-properties-preview > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > object-value-node > webkit-html-tag-name > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:82 Object with special numbers console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:84 {nan: NaN, posInf: Infinity, negInf: -Infinity, negZero: -0}nan: NaNnegInf: -InfinitynegZero: -0posInf: Infinity__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:84 {nan: NaN, posInf: Infinity, negInf: -Infinity, negZero: -0}nan: NaNnegInf: -InfinitynegZero: -0posInf: Infinity__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children console-object-preview.js:86 Object with exactly 5 properties: expected to be lossless console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text -console-object-preview.js:87 {a: 1, b: 2, c: 3, d: 4, e: 5}a: 1b: 2c: 3d: 4e: 5__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children -console-object-preview.js:89 {null: null, undef: undefined, regexp: /^[regexp]$/g, bool: false}bool: falsenull: nullregexp: /^[regexp]$/gundef: undefined__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-properties-preview source-code > name > object-value-null > name > object-value-undefined > name > object-value-regexp > name > object-value-boolean > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-boolean value > children > selection fill > name > object-properties-section-separator > object-value-null value > children > parent > selection fill > name > object-properties-section-separator > object-value-regexp value > object-value-regexp > children > selection fill > name > object-properties-section-separator > object-value-undefined value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:87 {a: 1, b: 2, c: 3, d: 4, e: 5}a: 1b: 2c: 3d: 4e: 5__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > selection fill > name > object-properties-section-separator > object-value-number value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children +console-object-preview.js:89 {null: null, undef: undefined, regexp: /^[regexp]$/g, bool: false}bool: falsenull: nullregexp: /^[regexp]$/gundef: undefined__proto__: Object console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-object source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-properties-preview > name > object-value-null > name > object-value-undefined > name > object-value-regexp > name > object-value-boolean > object-state-note info-note > children expanded > selection fill > name > object-properties-section-separator > object-value-boolean value > children > selection fill > name > object-properties-section-separator > object-value-null value > children > parent > selection fill > name > object-properties-section-separator > object-value-regexp value > object-value-regexp > children > selection fill > name > object-properties-section-separator > object-value-undefined value > children > parent > selection fill > name object-properties-section-dimmed > object-properties-section-separator > object-value-object value > children
diff --git a/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-proxy-expected.txt b/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-proxy-expected.txt index 45ae5662..b319e97 100644 --- a/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-proxy-expected.txt +++ b/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-proxy-expected.txt
@@ -1,10 +1,10 @@ Tests that console logging dumps proxy properly. -console-proxy.js:25 Proxy {boo: 42, foo: 43} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > object-state-note info-note > children -console-proxy.js:27 Proxy {boo: 42, foo: 43} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-proxy.js:25 Proxy {boo: 42, foo: 43} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > object-state-note info-note > children +console-proxy.js:27 Proxy {boo: 42, foo: 43} console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > object-state-note info-note > children window.accessedGet = false info-note display: inline-block -console-proxy.js:25 Proxy {boo: 42, foo: 43}[[Handler]]: Object[[Target]]: Object[[IsRevoked]]: false console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > selection fill > name > object-properties-section-separator > object-value-boolean value > children -console-proxy.js:27 Proxy {boo: 42, foo: 43}[[Handler]]: Object[[Target]]: Proxy[[IsRevoked]]: false console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object-preview > object-description > object-properties-preview source-code > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > parent > selection fill > name > object-properties-section-separator > object-value-proxy value > children > selection fill > name > object-properties-section-separator > object-value-boolean value > children +console-proxy.js:25 Proxy {boo: 42, foo: 43}[[Handler]]: Object[[Target]]: Object[[IsRevoked]]: false console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > selection fill > name > object-properties-section-separator > object-value-boolean value > children +console-proxy.js:27 Proxy {boo: 42, foo: 43}[[Handler]]: Object[[Target]]: Proxy[[IsRevoked]]: false console-message > source-code > console-message-anchor > devtools-link > hidden console-message-badge > hide-badge-title > console-message-text > console-view-object-properties-section object-value-proxy source-code expanded > tree-outline-disclosure tree-outline-disclosure-hide-overflow > tree-outline source-code object-properties-section > parent object-properties-section-root-element expanded > selection fill > console-object console-object-preview > object-description > object-properties-preview > name > object-value-number > name > object-value-number > object-state-note info-note > children expanded > parent > selection fill > name > object-properties-section-separator > object-value-object value > children > parent > selection fill > name > object-properties-section-separator > object-value-proxy value > children > selection fill > name > object-properties-section-separator > object-value-boolean value > children window.accessedGet = false
diff --git a/third_party/WebKit/LayoutTests/typedcssom/resources/testhelper.js b/third_party/WebKit/LayoutTests/typedcssom/resources/testhelper.js index 811dc752..df76068 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/resources/testhelper.js +++ b/third_party/WebKit/LayoutTests/typedcssom/resources/testhelper.js
@@ -60,13 +60,3 @@ 'turn', 's', 'ms', 'Hz', 'kHz', 'dpi', 'dpcm', 'dppx', 'fr', ]; - -// Hacky way of creating a CSSVariableReferenceValue -// since it doesn't expose a constructor. -function createReferenceValue(variable, fallback) { - const varExpr = 'var(' + variable + ')'; - const unparsedValue = newDivWithStyle('color:' + varExpr).attributeStyleMap.get('color'); - let referenceValue = unparsedValue[0]; - referenceValue.fallback = fallback; - return referenceValue; -}
diff --git a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-normalization/normalize-tokens.html b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-normalization/normalize-tokens.html index f871699..a5cf79b 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-normalization/normalize-tokens.html +++ b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-normalization/normalize-tokens.html
@@ -22,28 +22,28 @@ { value: 'var(--A)', expectedResult: [ - createReferenceValue('--A', null), + new CSSVariableReferenceValue('--A'), ] }, { value: 'var(--A, 1em)', expectedResult: [ - createReferenceValue('--A', new CSSUnparsedValue(' 1em')), + new CSSVariableReferenceValue('--A', new CSSUnparsedValue(' 1em')), ] }, { value: 'var(--A, var(--B))', expectedResult: [ - createReferenceValue('--A', new CSSUnparsedValue(' ', createReferenceValue('--B', null))), + new CSSVariableReferenceValue('--A', new CSSUnparsedValue(' ', new CSSVariableReferenceValue('--B'))), ] }, { value: 'calc(42px + var(--foo, 15em) + var(--bar, var(--far) + 15px))', expectedResult: [ 'calc(42px +', - createReferenceValue('--foo', new CSSUnparsedValue(' 15em')), + new CSSVariableReferenceValue('--foo', new CSSUnparsedValue(' 15em')), ' + ', - createReferenceValue('--bar', new CSSUnparsedValue(' ', createReferenceValue('--far', null), ' + 15px')), + new CSSVariableReferenceValue('--bar', new CSSUnparsedValue(' ', new CSSVariableReferenceValue('--far'), ' + 15px')), ')', ] },
diff --git a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-serialization/cssUnparsedValue.html b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-serialization/cssUnparsedValue.html index efd04e5..320503d4 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-serialization/cssUnparsedValue.html +++ b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-serialization/cssUnparsedValue.html
@@ -14,23 +14,23 @@ }, 'CSSUnparsedValue constructed from IDL with strings serializes correctly'); test(() => { - assert_equals(new CSSUnparsedValue(createReferenceValue('--A')).toString(), 'var(--A)'); + assert_equals(new CSSUnparsedValue(new CSSVariableReferenceValue('--A')).toString(), 'var(--A)'); assert_equals(new CSSUnparsedValue( - createReferenceValue('--A'), - createReferenceValue('--B')).toString(), + new CSSVariableReferenceValue('--A'), + new CSSVariableReferenceValue('--B')).toString(), 'var(--A)var(--B)'); assert_equals(new CSSUnparsedValue( - createReferenceValue('--A', - new CSSUnparsedValue(createReferenceValue('--B'))), - createReferenceValue('--C')).toString(), + new CSSVariableReferenceValue('--A', + new CSSUnparsedValue(new CSSVariableReferenceValue('--B'))), + new CSSVariableReferenceValue('--C')).toString(), 'var(--A,var(--B))var(--C)'); }, 'CSSUnparsedValue constructed from IDL with CSSVariableReferenceValues serializes correctly'); test(() => { assert_equals(new CSSUnparsedValue('foo', 'bar ', - createReferenceValue('--A', - new CSSUnparsedValue('baz ', createReferenceValue('--B'), 'lemon')), - createReferenceValue('--C', + new CSSVariableReferenceValue('--A', + new CSSUnparsedValue('baz ', new CSSVariableReferenceValue('--B'), 'lemon')), + new CSSVariableReferenceValue('--C', new CSSUnparsedValue('ade'))).toString(), 'foobar var(--A,baz var(--B)lemon)var(--C,ade)'); }, 'CSSUnparsedValue constructed from IDL with mix of strings and CSSVariableReferenceValues serializes correctly');
diff --git a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssUnparsedValue.html b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssUnparsedValue.html index 8e02172..e663db4 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssUnparsedValue.html +++ b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssUnparsedValue.html
@@ -11,9 +11,9 @@ const gValidTestArgs = [ { args: [], desc: 'no arguments' }, { args: [''], desc: 'an empty string' }, - { args: [createReferenceValue('--foo', null)], desc: 'a CSSVariableReferenceValue' }, + { args: [new CSSVariableReferenceValue('--foo')], desc: 'a CSSVariableReferenceValue' }, { - args: ['foo', 'bar', createReferenceValue('--A', null), 'baz', createReferenceValue('--B', null)], + args: ['foo', 'bar', new CSSVariableReferenceValue('--A'), 'baz', new CSSVariableReferenceValue('--B')], desc: 'mix of strings and CSSVariableReferenceValues' }, ];
diff --git a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue-expected.txt b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue-expected.txt index 965f8ea..576d301 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue-expected.txt +++ b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue-expected.txt
@@ -1,5 +1,8 @@ This is a testharness.js-based test. -FAIL Setting CSSVariableReferenceValue.variable to an invalid variable name throws SyntaxError assert_throws: function "() => result.variable = 'bar'" did not throw +FAIL Constructing a CSSVariableReferenceValue with an invalid variable name throws SyntaxError assert_throws: function "() => new CSSVariableReferenceValue('bar')" did not throw +FAIL Updating CSSVariableReferenceValue.variable to an invalid variable name throws SyntaxError assert_throws: function "() => result.variable = 'bar'" did not throw +PASS CSSVariableReferenceValue can be constructed with no fallback +PASS CSSVariableReferenceValue can be constructed with fallback PASS CSSVariableReferenceValue.variable can updated to a valid variable name PASS CSSVariableReferenceValue.fallback can updated to null PASS CSSVariableReferenceValue.fallback can updated to a CSSUnparsedValue
diff --git a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue.html b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue.html index ebbdefe2..5b6e990 100644 --- a/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue.html +++ b/third_party/WebKit/LayoutTests/typedcssom/stylevalue-subclasses/cssVariableReferenceValue.html
@@ -9,27 +9,44 @@ 'use strict'; test(() => { - let result = createReferenceValue('--foo', null); + assert_throws(new SyntaxError(), () => new CSSVariableReferenceValue('bar')); + assert_throws(new SyntaxError(), () => new CSSVariableReferenceValue('')); +}, 'Constructing a CSSVariableReferenceValue with an invalid variable name throws SyntaxError'); + +test(() => { + let result = new CSSVariableReferenceValue('--foo'); assert_throws(new SyntaxError(), () => result.variable = 'bar'); assert_equals(result.variable, '--foo'); assert_throws(new SyntaxError(), () => result.variable = ''); assert_equals(result.variable, '--foo'); -}, 'Setting CSSVariableReferenceValue.variable to an invalid variable name throws SyntaxError'); +}, 'Updating CSSVariableReferenceValue.variable to an invalid variable name throws SyntaxError'); test(() => { - let result = createReferenceValue('--foo', null); + const result = new CSSVariableReferenceValue('--foo'); + assert_equals(result.variable, '--foo'); + assert_equals(result.fallback, null); +}, 'CSSVariableReferenceValue can be constructed with no fallback'); + +test(() => { + const result = new CSSVariableReferenceValue('--foo', new CSSUnparsedValue('lemon')); + assert_equals(result.variable, '--foo'); + assert_style_value_equals(result.fallback, new CSSUnparsedValue('lemon')); +}, 'CSSVariableReferenceValue can be constructed with fallback'); + +test(() => { + let result = new CSSVariableReferenceValue('--foo'); result.variable = '--bar'; assert_equals(result.variable, '--bar'); }, 'CSSVariableReferenceValue.variable can updated to a valid variable name'); test(() => { - let result = createReferenceValue('--foo', new CSSUnparsedValue()); + let result = new CSSVariableReferenceValue('--foo', new CSSUnparsedValue()); result.fallback = null; assert_equals(result.fallback, null); }, 'CSSVariableReferenceValue.fallback can updated to null'); test(() => { - let result = createReferenceValue('--foo', null); + let result = new CSSVariableReferenceValue('--foo'); result.fallback = new CSSUnparsedValue('foo'); assert_style_value_equals(result.fallback, new CSSUnparsedValue('foo')); }, 'CSSVariableReferenceValue.fallback can updated to a CSSUnparsedValue');
diff --git a/third_party/WebKit/Source/build/scripts/core/style/templates/ComputedStyleInitialValues.h.tmpl b/third_party/WebKit/Source/build/scripts/core/style/templates/ComputedStyleInitialValues.h.tmpl index cecd50c..f641737 100644 --- a/third_party/WebKit/Source/build/scripts/core/style/templates/ComputedStyleInitialValues.h.tmpl +++ b/third_party/WebKit/Source/build/scripts/core/style/templates/ComputedStyleInitialValues.h.tmpl
@@ -40,7 +40,7 @@ OverflowAlignment::kDefault); } static StyleSelfAlignmentData InitialDefaultAlignment() { - return StyleSelfAlignmentData(kItemPositionNormal, + return StyleSelfAlignmentData(ItemPosition::kNormal, OverflowAlignment::kDefault); } static StyleImage* InitialBorderImageSource() { return nullptr; }
diff --git a/third_party/WebKit/Source/core/css/CSSPrimitiveValueMappings.h b/third_party/WebKit/Source/core/css/CSSPrimitiveValueMappings.h index 9f0fa69..df5af1a2 100644 --- a/third_party/WebKit/Source/core/css/CSSPrimitiveValueMappings.h +++ b/third_party/WebKit/Source/core/css/CSSPrimitiveValueMappings.h
@@ -1554,46 +1554,46 @@ inline CSSIdentifierValue::CSSIdentifierValue(ItemPosition item_position) : CSSValue(kIdentifierClass) { switch (item_position) { - case kItemPositionAuto: + case ItemPosition::kAuto: value_id_ = CSSValueAuto; break; - case kItemPositionNormal: + case ItemPosition::kNormal: value_id_ = CSSValueNormal; break; - case kItemPositionStretch: + case ItemPosition::kStretch: value_id_ = CSSValueStretch; break; - case kItemPositionBaseline: + case ItemPosition::kBaseline: value_id_ = CSSValueBaseline; break; - case kItemPositionLastBaseline: + case ItemPosition::kLastBaseline: value_id_ = CSSValueLastBaseline; break; - case kItemPositionCenter: + case ItemPosition::kCenter: value_id_ = CSSValueCenter; break; - case kItemPositionStart: + case ItemPosition::kStart: value_id_ = CSSValueStart; break; - case kItemPositionEnd: + case ItemPosition::kEnd: value_id_ = CSSValueEnd; break; - case kItemPositionSelfStart: + case ItemPosition::kSelfStart: value_id_ = CSSValueSelfStart; break; - case kItemPositionSelfEnd: + case ItemPosition::kSelfEnd: value_id_ = CSSValueSelfEnd; break; - case kItemPositionFlexStart: + case ItemPosition::kFlexStart: value_id_ = CSSValueFlexStart; break; - case kItemPositionFlexEnd: + case ItemPosition::kFlexEnd: value_id_ = CSSValueFlexEnd; break; - case kItemPositionLeft: + case ItemPosition::kLeft: value_id_ = CSSValueLeft; break; - case kItemPositionRight: + case ItemPosition::kRight: value_id_ = CSSValueRight; break; } @@ -1603,40 +1603,40 @@ inline ItemPosition CSSIdentifierValue::ConvertTo() const { switch (value_id_) { case CSSValueAuto: - return kItemPositionAuto; + return ItemPosition::kAuto; case CSSValueNormal: - return kItemPositionNormal; + return ItemPosition::kNormal; case CSSValueStretch: - return kItemPositionStretch; + return ItemPosition::kStretch; case CSSValueBaseline: - return kItemPositionBaseline; + return ItemPosition::kBaseline; case CSSValueFirstBaseline: - return kItemPositionBaseline; + return ItemPosition::kBaseline; case CSSValueLastBaseline: - return kItemPositionLastBaseline; + return ItemPosition::kLastBaseline; case CSSValueCenter: - return kItemPositionCenter; + return ItemPosition::kCenter; case CSSValueStart: - return kItemPositionStart; + return ItemPosition::kStart; case CSSValueEnd: - return kItemPositionEnd; + return ItemPosition::kEnd; case CSSValueSelfStart: - return kItemPositionSelfStart; + return ItemPosition::kSelfStart; case CSSValueSelfEnd: - return kItemPositionSelfEnd; + return ItemPosition::kSelfEnd; case CSSValueFlexStart: - return kItemPositionFlexStart; + return ItemPosition::kFlexStart; case CSSValueFlexEnd: - return kItemPositionFlexEnd; + return ItemPosition::kFlexEnd; case CSSValueLeft: - return kItemPositionLeft; + return ItemPosition::kLeft; case CSSValueRight: - return kItemPositionRight; + return ItemPosition::kRight; default: break; } NOTREACHED(); - return kItemPositionAuto; + return ItemPosition::kAuto; } template <>
diff --git a/third_party/WebKit/Source/core/css/CSSProperties.json5 b/third_party/WebKit/Source/core/css/CSSProperties.json5 index 668a866..cfcddde 100644 --- a/third_party/WebKit/Source/core/css/CSSProperties.json5 +++ b/third_party/WebKit/Source/core/css/CSSProperties.json5
@@ -717,7 +717,7 @@ field_group: "*", field_template: "external", include_paths: ["core/style/StyleSelfAlignmentData.h"], - default_value: "StyleSelfAlignmentData(kItemPositionNormal, OverflowAlignment::kDefault)", + default_value: "StyleSelfAlignmentData(ItemPosition::kNormal, OverflowAlignment::kDefault)", type_name: "StyleSelfAlignmentData", converter: "ConvertSelfOrDefaultAlignmentData", }, @@ -732,7 +732,7 @@ field_group: "*", field_template: "external", include_paths: ["core/style/StyleSelfAlignmentData.h"], - default_value: "StyleSelfAlignmentData(kItemPositionAuto, OverflowAlignment::kDefault)", + default_value: "StyleSelfAlignmentData(ItemPosition::kAuto, OverflowAlignment::kDefault)", type_name: "StyleSelfAlignmentData", converter: "ConvertSelfOrDefaultAlignmentData", }, @@ -1668,7 +1668,7 @@ field_group: "*", field_template: "external", include_paths: ["core/style/StyleSelfAlignmentData.h"], - default_value: "StyleSelfAlignmentData(kItemPositionAuto, OverflowAlignment::kDefault)", + default_value: "StyleSelfAlignmentData(ItemPosition::kAuto, OverflowAlignment::kDefault)", type_name: "StyleSelfAlignmentData", converter: "ConvertSelfOrDefaultAlignmentData", }, @@ -1679,7 +1679,7 @@ field_group: "*", field_template: "external", include_paths: ["core/style/StyleSelfAlignmentData.h"], - default_value: "StyleSelfAlignmentData(kItemPositionAuto, OverflowAlignment::kDefault)", + default_value: "StyleSelfAlignmentData(ItemPosition::kAuto, OverflowAlignment::kDefault)", type_name: "StyleSelfAlignmentData", converter: "ConvertSelfOrDefaultAlignmentData", },
diff --git a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp index 31d4014a1..38e27e6 100644 --- a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp +++ b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
@@ -501,14 +501,14 @@ static CSSValueList* ValueForItemPositionWithOverflowAlignment( const StyleSelfAlignmentData& data) { CSSValueList* result = CSSValueList::CreateSpaceSeparated(); - if (data.PositionType() == kLegacyPosition) + if (data.PositionType() == ItemPositionType::kLegacy) result->Append(*CSSIdentifierValue::Create(CSSValueLegacy)); - if (data.GetPosition() == kItemPositionBaseline) { + if (data.GetPosition() == ItemPosition::kBaseline) { result->Append( *CSSValuePair::Create(CSSIdentifierValue::Create(CSSValueBaseline), CSSIdentifierValue::Create(CSSValueBaseline), CSSValuePair::kDropIdenticalValues)); - } else if (data.GetPosition() == kItemPositionLastBaseline) { + } else if (data.GetPosition() == ItemPosition::kLastBaseline) { result->Append( *CSSValuePair::Create(CSSIdentifierValue::Create(CSSValueLast), CSSIdentifierValue::Create(CSSValueBaseline), @@ -516,7 +516,7 @@ } else { result->Append(*CSSIdentifierValue::Create(data.GetPosition())); } - if (data.GetPosition() >= kItemPositionCenter && + if (data.GetPosition() >= ItemPosition::kCenter && data.Overflow() != OverflowAlignment::kDefault) result->Append(*CSSIdentifierValue::Create(data.Overflow())); DCHECK_LE(result->length(), 2u); @@ -2715,7 +2715,7 @@ return CSSIdentifierValue::Create(style.Isolation()); case CSSPropertyJustifyItems: return ValueForItemPositionWithOverflowAlignment( - style.JustifyItems().GetPosition() == kItemPositionAuto + style.JustifyItems().GetPosition() == ItemPosition::kAuto ? ComputedStyleInitialValues::InitialDefaultAlignment() : style.JustifyItems()); case CSSPropertyJustifySelf:
diff --git a/third_party/WebKit/Source/core/css/cssom/CSSStyleVariableReferenceValue.h b/third_party/WebKit/Source/core/css/cssom/CSSStyleVariableReferenceValue.h index 579299f..17997ff 100644 --- a/third_party/WebKit/Source/core/css/cssom/CSSStyleVariableReferenceValue.h +++ b/third_party/WebKit/Source/core/css/cssom/CSSStyleVariableReferenceValue.h
@@ -21,8 +21,9 @@ public: virtual ~CSSStyleVariableReferenceValue() = default; - static CSSStyleVariableReferenceValue* Create(const String& variable, - CSSUnparsedValue* fallback) { + static CSSStyleVariableReferenceValue* Create( + const String& variable, + CSSUnparsedValue* fallback = nullptr) { return new CSSStyleVariableReferenceValue(variable, fallback); }
diff --git a/third_party/WebKit/Source/core/css/cssom/CSSVariableReferenceValue.idl b/third_party/WebKit/Source/core/css/cssom/CSSVariableReferenceValue.idl index 62004e5..4d17cec 100644 --- a/third_party/WebKit/Source/core/css/cssom/CSSVariableReferenceValue.idl +++ b/third_party/WebKit/Source/core/css/cssom/CSSVariableReferenceValue.idl
@@ -5,6 +5,7 @@ // Represents a CSS var() reference in a CSS value. // Spec: https://drafts.css-houdini.org/css-typed-om/#cssvariablereferencevalue [ + Constructor(DOMString variable, optional CSSUnparsedValue fallback), Exposed=(Window,PaintWorklet), RuntimeEnabled=CSSTypedOM, ImplementedAs=CSSStyleVariableReferenceValue
diff --git a/third_party/WebKit/Source/core/css/resolver/StyleAdjuster.cpp b/third_party/WebKit/Source/core/css/resolver/StyleAdjuster.cpp index 0cd1689..7f5bedb 100644 --- a/third_party/WebKit/Source/core/css/resolver/StyleAdjuster.cpp +++ b/third_party/WebKit/Source/core/css/resolver/StyleAdjuster.cpp
@@ -589,8 +589,8 @@ // If the inherited value of justify-items includes the 'legacy' keyword, // 'auto' computes to the the inherited value. Otherwise, 'auto' computes to // 'normal'. - if (style.JustifyItemsPosition() == kItemPositionAuto) { - if (parent_style.JustifyItemsPositionType() == kLegacyPosition) + if (style.JustifyItemsPosition() == ItemPosition::kAuto) { + if (parent_style.JustifyItemsPositionType() == ItemPositionType::kLegacy) style.SetJustifyItems(parent_style.JustifyItems()); }
diff --git a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp index ee46a4a..d3c5454a 100644 --- a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp +++ b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp
@@ -685,15 +685,15 @@ if (value.IsValuePair()) { const CSSValuePair& pair = ToCSSValuePair(value); if (ToCSSIdentifierValue(pair.First()).GetValueID() == CSSValueLegacy) { - alignment_data.SetPositionType(kLegacyPosition); + alignment_data.SetPositionType(ItemPositionType::kLegacy); alignment_data.SetPosition( ToCSSIdentifierValue(pair.Second()).ConvertTo<ItemPosition>()); } else if (ToCSSIdentifierValue(pair.First()).GetValueID() == CSSValueFirst) { - alignment_data.SetPosition(kItemPositionBaseline); + alignment_data.SetPosition(ItemPosition::kBaseline); } else if (ToCSSIdentifierValue(pair.First()).GetValueID() == CSSValueLast) { - alignment_data.SetPosition(kItemPositionLastBaseline); + alignment_data.SetPosition(ItemPosition::kLastBaseline); } else { alignment_data.SetPosition( ToCSSIdentifierValue(pair.First()).ConvertTo<ItemPosition>());
diff --git a/third_party/WebKit/Source/core/layout/BaselineAlignment.h b/third_party/WebKit/Source/core/layout/BaselineAlignment.h index 8ec7afa..288445a 100644 --- a/third_party/WebKit/Source/core/layout/BaselineAlignment.h +++ b/third_party/WebKit/Source/core/layout/BaselineAlignment.h
@@ -75,8 +75,8 @@ }; static inline bool IsBaselinePosition(ItemPosition position) { - return position == kItemPositionBaseline || - position == kItemPositionLastBaseline; + return position == ItemPosition::kBaseline || + position == ItemPosition::kLastBaseline; } } // namespace blink
diff --git a/third_party/WebKit/Source/core/layout/FlexibleBoxAlgorithm.cpp b/third_party/WebKit/Source/core/layout/FlexibleBoxAlgorithm.cpp index de1f0f3b..fc053de2 100644 --- a/third_party/WebKit/Source/core/layout/FlexibleBoxAlgorithm.cpp +++ b/third_party/WebKit/Source/core/layout/FlexibleBoxAlgorithm.cpp
@@ -311,7 +311,7 @@ flex_item.UpdateAutoMarginsInMainAxis(auto_margin_offset); LayoutUnit child_cross_axis_margin_box_extent; - if (flex_item.Alignment() == kItemPositionBaseline && + if (flex_item.Alignment() == ItemPosition::kBaseline && !flex_item.HasAutoMarginsInCrossAxis()) { LayoutUnit ascent = flex_item.MarginBoxAscent(); LayoutUnit descent = @@ -506,20 +506,20 @@ const ComputedStyle& flexbox_style, const ComputedStyle& child_style) { ItemPosition align = - child_style.ResolvedAlignSelf(kItemPositionStretch, &flexbox_style) + child_style.ResolvedAlignSelf(ItemPosition::kStretch, &flexbox_style) .GetPosition(); - DCHECK_NE(align, kItemPositionAuto); - DCHECK_NE(align, kItemPositionNormal); + DCHECK_NE(align, ItemPosition::kAuto); + DCHECK_NE(align, ItemPosition::kNormal); - if (align == kItemPositionBaseline && + if (align == ItemPosition::kBaseline && IsHorizontalFlow(flexbox_style) != child_style.IsHorizontalWritingMode()) - align = kItemPositionFlexStart; + align = ItemPosition::kFlexStart; if (flexbox_style.FlexWrap() == EFlexWrap::kWrapReverse) { - if (align == kItemPositionFlexStart) - align = kItemPositionFlexEnd; - else if (align == kItemPositionFlexEnd) - align = kItemPositionFlexStart; + if (align == ItemPosition::kFlexStart) + align = ItemPosition::kFlexEnd; + else if (align == ItemPosition::kFlexEnd) + align = ItemPosition::kFlexStart; } return align;
diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.cpp b/third_party/WebKit/Source/core/layout/LayoutBox.cpp index fe975f72..cd99464b 100644 --- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp +++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
@@ -2949,7 +2949,7 @@ .ResolvedAlignSelf( ContainingBlock()->SelfAlignmentNormalBehavior(), &parent_style) - .GetPosition() == kItemPositionStretch; + .GetPosition() == ItemPosition::kStretch; } bool LayoutBox::IsStretchingColumnFlexItem() const { @@ -2983,15 +2983,16 @@ // Flexbox Items, which obviously should have a container. return false; } - if (cb->IsHorizontalWritingMode() != IsHorizontalWritingMode()) + if (cb->IsHorizontalWritingMode() != IsHorizontalWritingMode()) { return style .ResolvedAlignSelf(cb->SelfAlignmentNormalBehavior(this), cb->Style()) - .GetPosition() == kItemPositionStretch; + .GetPosition() == ItemPosition::kStretch; + } return style .ResolvedJustifySelf(cb->SelfAlignmentNormalBehavior(this), cb->Style()) - .GetPosition() == kItemPositionStretch; + .GetPosition() == ItemPosition::kStretch; } bool LayoutBox::SizesLogicalWidthToFitContent(
diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.h b/third_party/WebKit/Source/core/layout/LayoutBox.h index 2588f73..b0c5387 100644 --- a/third_party/WebKit/Source/core/layout/LayoutBox.h +++ b/third_party/WebKit/Source/core/layout/LayoutBox.h
@@ -1413,7 +1413,7 @@ virtual ItemPosition SelfAlignmentNormalBehavior( const LayoutBox* child = nullptr) const { DCHECK(!child); - return kItemPositionStretch; + return ItemPosition::kStretch; } // Returns false if it could not cheaply compute the extent (e.g. fixed
diff --git a/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp b/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp index 656983b..b5a17af6 100644 --- a/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp +++ b/third_party/WebKit/Source/core/layout/LayoutFlexibleBox.cpp
@@ -187,7 +187,7 @@ if (child->IsOutOfFlowPositioned()) continue; if (FlexLayoutAlgorithm::AlignmentForChild(StyleRef(), child->StyleRef()) == - kItemPositionBaseline && + ItemPosition::kBaseline && !HasAutoMarginsInCrossAxis(*child)) { baseline_child = child; break; @@ -331,7 +331,7 @@ if (old_style && old_style->ResolvedAlignItems(SelfAlignmentNormalBehavior()) - .GetPosition() == kItemPositionStretch && + .GetPosition() == ItemPosition::kStretch && diff.NeedsFullLayout()) { // Flex items that were previously stretching need to be relayed out so we // can compute new available cross axis space. This is only necessary for @@ -343,7 +343,7 @@ child->StyleRef() .ResolvedAlignSelf(SelfAlignmentNormalBehavior(), old_style) .GetPosition(); - if (previous_alignment == kItemPositionStretch && + if (previous_alignment == ItemPosition::kStretch && previous_alignment != child->StyleRef() .ResolvedAlignSelf(SelfAlignmentNormalBehavior(), Style()) @@ -1109,7 +1109,7 @@ LayoutUnit LayoutFlexibleBox::CrossSizeForPercentageResolution( const LayoutBox& child) { if (FlexLayoutAlgorithm::AlignmentForChild(StyleRef(), child.StyleRef()) != - kItemPositionStretch) + ItemPosition::kStretch) return LayoutUnit(-1); // Here we implement https://drafts.csswg.org/css-flexbox/#algo-stretch @@ -1228,11 +1228,11 @@ LayoutUnit max_ascent, bool is_wrap_reverse) { switch (position) { - case kItemPositionAuto: - case kItemPositionNormal: + case ItemPosition::kAuto: + case ItemPosition::kNormal: NOTREACHED(); break; - case kItemPositionStretch: + case ItemPosition::kStretch: // Actual stretching must be handled by the caller. Since wrap-reverse // flips cross start and cross end, stretch children should be aligned // with the cross end. This matters because applyStretchAlignment @@ -1242,24 +1242,24 @@ if (is_wrap_reverse) return available_free_space; break; - case kItemPositionFlexStart: + case ItemPosition::kFlexStart: break; - case kItemPositionFlexEnd: + case ItemPosition::kFlexEnd: return available_free_space; - case kItemPositionCenter: + case ItemPosition::kCenter: return available_free_space / 2; - case kItemPositionBaseline: + case ItemPosition::kBaseline: // FIXME: If we get here in columns, we want the use the descent, except // we currently can't get the ascent/descent of orthogonal children. // https://bugs.webkit.org/show_bug.cgi?id=98076 return max_ascent - ascent; - case kItemPositionLastBaseline: - case kItemPositionSelfStart: - case kItemPositionSelfEnd: - case kItemPositionStart: - case kItemPositionEnd: - case kItemPositionLeft: - case kItemPositionRight: + case ItemPosition::kLastBaseline: + case ItemPosition::kSelfStart: + case ItemPosition::kSelfEnd: + case ItemPosition::kStart: + case ItemPosition::kEnd: + case ItemPosition::kLeft: + case ItemPosition::kRight: // TODO(jferanndez): Implement these (https://crbug.com/722287). break; } @@ -1388,7 +1388,7 @@ // - We are vertical and the child is in horizontal writing mode // Otherwise, we need to stretch if the cross axis size is auto. if (FlexLayoutAlgorithm::AlignmentForChild(StyleRef(), child.StyleRef()) != - kItemPositionStretch) + ItemPosition::kStretch) return false; if (IsHorizontalFlow() != child.StyleRef().IsHorizontalWritingMode()) @@ -1634,7 +1634,7 @@ continue; ItemPosition position = flex_item.Alignment(); - if (position == kItemPositionStretch) + if (position == ItemPosition::kStretch) ApplyStretchAlignmentToChild(flex_item, line_cross_axis_extent); LayoutUnit available_space = flex_item.AvailableAlignmentSpace(line_cross_axis_extent); @@ -1642,7 +1642,7 @@ available_space, position, flex_item.MarginBoxAscent(), max_ascent, StyleRef().FlexWrap() == EFlexWrap::kWrapReverse); AdjustAlignmentForChild(*flex_item.box, offset); - if (position == kItemPositionBaseline && + if (position == ItemPosition::kBaseline && StyleRef().FlexWrap() == EFlexWrap::kWrapReverse) { min_margin_after_baseline = std::min( min_margin_after_baseline, @@ -1666,7 +1666,7 @@ for (size_t child_number = 0; child_number < line_context.line_items.size(); ++child_number) { const FlexItem& flex_item = line_context.line_items[child_number]; - if (flex_item.Alignment() == kItemPositionBaseline && + if (flex_item.Alignment() == ItemPosition::kBaseline && !flex_item.HasAutoMarginsInCrossAxis() && min_margin_after_baseline) AdjustAlignmentForChild(*flex_item.box, min_margin_after_baseline); }
diff --git a/third_party/WebKit/Source/core/layout/LayoutFullScreen.cpp b/third_party/WebKit/Source/core/layout/LayoutFullScreen.cpp index 329678c..ccfc132 100644 --- a/third_party/WebKit/Source/core/layout/LayoutFullScreen.cpp +++ b/third_party/WebKit/Source/core/layout/LayoutFullScreen.cpp
@@ -107,7 +107,7 @@ // TODO (lajava): Since the FullScrenn layout object is anonymous, its Default // Alignment (align-items) value can't be used to resolve its children Self // Alignment 'auto' values. - fullscreen_style->SetAlignItemsPosition(kItemPositionCenter); + fullscreen_style->SetAlignItemsPosition(ItemPosition::kCenter); fullscreen_style->SetFlexDirection(EFlexDirection::kColumn); fullscreen_style->SetPosition(EPosition::kFixed);
diff --git a/third_party/WebKit/Source/core/layout/LayoutFullScreen.h b/third_party/WebKit/Source/core/layout/LayoutFullScreen.h index 48ee1905..6964f49 100644 --- a/third_party/WebKit/Source/core/layout/LayoutFullScreen.h +++ b/third_party/WebKit/Source/core/layout/LayoutFullScreen.h
@@ -69,7 +69,7 @@ ItemPosition SelfAlignmentNormalBehavior( const LayoutBox* child = nullptr) const override { DCHECK(!child); - return kItemPositionCenter; + return ItemPosition::kCenter; } };
diff --git a/third_party/WebKit/Source/core/layout/LayoutGrid.cpp b/third_party/WebKit/Source/core/layout/LayoutGrid.cpp index 209ed411..558d07a 100644 --- a/third_party/WebKit/Source/core/layout/LayoutGrid.cpp +++ b/third_party/WebKit/Source/core/layout/LayoutGrid.cpp
@@ -109,15 +109,17 @@ StyleSelfAlignmentData LayoutGrid::DefaultAlignment( GridAxis axis, const ComputedStyle& style) const { - return axis == kGridRowAxis ? style.ResolvedJustifyItems(kItemPositionNormal) - : style.ResolvedAlignItems(kItemPositionNormal); + return axis == kGridRowAxis + ? style.ResolvedJustifyItems(ItemPosition::kNormal) + : style.ResolvedAlignItems(ItemPosition::kNormal); } bool LayoutGrid::DefaultAlignmentIsStretchOrNormal( GridAxis axis, const ComputedStyle& style) const { ItemPosition alignment = DefaultAlignment(axis, style).GetPosition(); - return alignment == kItemPositionStretch || alignment == kItemPositionNormal; + return alignment == ItemPosition::kStretch || + alignment == ItemPosition::kNormal; } bool LayoutGrid::SelfAlignmentChangedSize(GridAxis axis, @@ -125,11 +127,11 @@ const ComputedStyle& new_style, const LayoutBox& child) const { return SelfAlignmentForChild(axis, child, &old_style).GetPosition() == - kItemPositionStretch + ItemPosition::kStretch ? SelfAlignmentForChild(axis, child, &new_style).GetPosition() != - kItemPositionStretch + ItemPosition::kStretch : SelfAlignmentForChild(axis, child, &new_style).GetPosition() == - kItemPositionStretch; + ItemPosition::kStretch; } bool LayoutGrid::DefaultAlignmentChangedSize( @@ -1821,7 +1823,7 @@ return kGridAxisStart; switch (AlignSelfForChild(child).GetPosition()) { - case kItemPositionSelfStart: + case ItemPosition::kSelfStart: // TODO (lajava): Should we implement this logic in a generic utility // function? // Aligns the alignment subject to be flush with the edge of the alignment @@ -1838,7 +1840,7 @@ // self-start is based on the child's block-flow direction. That's why we // need to check against the grid container's block-flow direction. return has_same_writing_mode ? kGridAxisStart : kGridAxisEnd; - case kItemPositionSelfEnd: + case ItemPosition::kSelfEnd: // TODO (lajava): Should we implement this logic in a generic utility // function? // Aligns the alignment subject to be flush with the edge of the alignment @@ -1855,37 +1857,37 @@ // self-end is based on the child's block-flow direction. That's why we // need to check against the grid container's block-flow direction. return has_same_writing_mode ? kGridAxisEnd : kGridAxisStart; - case kItemPositionLeft: + case ItemPosition::kLeft: // Aligns the alignment subject to be flush with the alignment container's // 'line-left' edge. The alignment axis (column axis) is always orthogonal // to the inline axis, hence this value behaves as 'start'. return kGridAxisStart; - case kItemPositionRight: + case ItemPosition::kRight: // Aligns the alignment subject to be flush with the alignment container's // 'line-right' edge. The alignment axis (column axis) is always // orthogonal to the inline axis, hence this value behaves as 'start'. return kGridAxisStart; - case kItemPositionCenter: + case ItemPosition::kCenter: return kGridAxisCenter; // Only used in flex layout, otherwise equivalent to 'start'. - case kItemPositionFlexStart: + case ItemPosition::kFlexStart: // Aligns the alignment subject to be flush with the alignment container's // 'start' edge (block-start) in the column axis. - case kItemPositionStart: + case ItemPosition::kStart: return kGridAxisStart; // Only used in flex layout, otherwise equivalent to 'end'. - case kItemPositionFlexEnd: + case ItemPosition::kFlexEnd: // Aligns the alignment subject to be flush with the alignment container's // 'end' edge (block-end) in the column axis. - case kItemPositionEnd: + case ItemPosition::kEnd: return kGridAxisEnd; - case kItemPositionStretch: + case ItemPosition::kStretch: return kGridAxisStart; - case kItemPositionBaseline: - case kItemPositionLastBaseline: + case ItemPosition::kBaseline: + case ItemPosition::kLastBaseline: return kGridAxisStart; - case kItemPositionAuto: - case kItemPositionNormal: + case ItemPosition::kAuto: + case ItemPosition::kNormal: break; } @@ -1902,7 +1904,7 @@ return kGridAxisStart; switch (JustifySelfForChild(child).GetPosition()) { - case kItemPositionSelfStart: + case ItemPosition::kSelfStart: // TODO (lajava): Should we implement this logic in a generic utility // function? // Aligns the alignment subject to be flush with the edge of the alignment @@ -1918,7 +1920,7 @@ // self-start is based on the child's inline-flow direction. That's why we // need to check against the grid container's direction. return has_same_direction ? kGridAxisStart : kGridAxisEnd; - case kItemPositionSelfEnd: + case ItemPosition::kSelfEnd: // TODO (lajava): Should we implement this logic in a generic utility // function? // Aligns the alignment subject to be flush with the edge of the alignment @@ -1934,37 +1936,37 @@ // self-end is based on the child's inline-flow direction. That's why we // need to check against the grid container's direction. return has_same_direction ? kGridAxisEnd : kGridAxisStart; - case kItemPositionLeft: + case ItemPosition::kLeft: // Aligns the alignment subject to be flush with the alignment container's // 'line-left' edge. We want the physical 'left' side, so we have to take // account, container's inline-flow direction. return grid_is_ltr ? kGridAxisStart : kGridAxisEnd; - case kItemPositionRight: + case ItemPosition::kRight: // Aligns the alignment subject to be flush with the alignment container's // 'line-right' edge. We want the physical 'right' side, so we have to // take account, container's inline-flow direction. return grid_is_ltr ? kGridAxisEnd : kGridAxisStart; - case kItemPositionCenter: + case ItemPosition::kCenter: return kGridAxisCenter; // Only used in flex layout, otherwise equivalent to 'start'. - case kItemPositionFlexStart: + case ItemPosition::kFlexStart: // Aligns the alignment subject to be flush with the alignment container's // 'start' edge (inline-start) in the row axis. - case kItemPositionStart: + case ItemPosition::kStart: return kGridAxisStart; // Only used in flex layout, otherwise equivalent to 'end'. - case kItemPositionFlexEnd: + case ItemPosition::kFlexEnd: // Aligns the alignment subject to be flush with the alignment container's // 'end' edge (inline-end) in the row axis. - case kItemPositionEnd: + case ItemPosition::kEnd: return kGridAxisEnd; - case kItemPositionStretch: + case ItemPosition::kStretch: return kGridAxisStart; - case kItemPositionBaseline: - case kItemPositionLastBaseline: + case ItemPosition::kBaseline: + case ItemPosition::kLastBaseline: return kGridAxisStart; - case kItemPositionAuto: - case kItemPositionNormal: + case ItemPosition::kAuto: + case ItemPosition::kNormal: break; }
diff --git a/third_party/WebKit/Source/core/layout/LayoutGrid.h b/third_party/WebKit/Source/core/layout/LayoutGrid.h index 9fc1963..3aeb136 100644 --- a/third_party/WebKit/Source/core/layout/LayoutGrid.h +++ b/third_party/WebKit/Source/core/layout/LayoutGrid.h
@@ -114,8 +114,8 @@ ItemPosition SelfAlignmentNormalBehavior( const LayoutBox* child = nullptr) const override { DCHECK(child); - return child->IsLayoutReplaced() ? kItemPositionStart - : kItemPositionStretch; + return child->IsLayoutReplaced() ? ItemPosition::kStart + : ItemPosition::kStretch; } private: @@ -262,11 +262,11 @@ : child.StyleRef().Height().IsAuto(); } bool AllowedToStretchChildAlongColumnAxis(const LayoutBox& child) const { - return AlignSelfForChild(child).GetPosition() == kItemPositionStretch && + return AlignSelfForChild(child).GetPosition() == ItemPosition::kStretch && HasAutoSizeInColumnAxis(child) && !HasAutoMarginsInColumnAxis(child); } bool AllowedToStretchChildAlongRowAxis(const LayoutBox& child) const { - return JustifySelfForChild(child).GetPosition() == kItemPositionStretch && + return JustifySelfForChild(child).GetPosition() == ItemPosition::kStretch && HasAutoSizeInRowAxis(child) && !HasAutoMarginsInRowAxis(child); } bool HasAutoMarginsInColumnAxis(const LayoutBox&) const;
diff --git a/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp b/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp index 3d30f0f..af642438e 100644 --- a/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp +++ b/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp
@@ -91,10 +91,10 @@ // when the content overflows, treat it the same as align-items: flex-start. // But we only do that for the cases where html.css would otherwise use // center. - if (Style()->AlignItemsPosition() == kItemPositionCenter) { + if (Style()->AlignItemsPosition() == ItemPosition::kCenter) { inner_style.SetMarginTop(Length()); inner_style.SetMarginBottom(Length()); - inner_style.SetAlignSelfPosition(kItemPositionFlexStart); + inner_style.SetAlignSelfPosition(ItemPosition::kFlexStart); } Length padding_start = Length(
diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.cpp b/third_party/WebKit/Source/core/style/ComputedStyle.cpp index 283ee58..28c47d91 100644 --- a/third_party/WebKit/Source/core/style/ComputedStyle.cpp +++ b/third_party/WebKit/Source/core/style/ComputedStyle.cpp
@@ -221,8 +221,8 @@ StyleSelfAlignmentData ResolvedSelfAlignment( const StyleSelfAlignmentData& value, ItemPosition normal_value_behavior) { - if (value.GetPosition() == kItemPositionNormal || - value.GetPosition() == kItemPositionAuto) + if (value.GetPosition() == ItemPosition::kNormal || + value.GetPosition() == ItemPosition::kAuto) return {normal_value_behavior, OverflowAlignment::kDefault}; return value; } @@ -239,7 +239,7 @@ const ComputedStyle* parent_style) const { // We will return the behaviour of 'normal' value if needed, which is specific // of each layout model. - if (!parent_style || AlignSelfPosition() != kItemPositionAuto) + if (!parent_style || AlignSelfPosition() != ItemPosition::kAuto) return ResolvedSelfAlignment(AlignSelf(), normal_value_behaviour); // The 'auto' keyword computes to the parent's align-items computed value. @@ -258,7 +258,7 @@ const ComputedStyle* parent_style) const { // We will return the behaviour of 'normal' value if needed, which is specific // of each layout model. - if (!parent_style || JustifySelfPosition() != kItemPositionAuto) + if (!parent_style || JustifySelfPosition() != ItemPosition::kAuto) return ResolvedSelfAlignment(JustifySelf(), normal_value_behaviour); // The auto keyword computes to the parent's justify-items computed value.
diff --git a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h index cca3fc97..fbc5ef2 100644 --- a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h +++ b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h
@@ -187,26 +187,26 @@ return a = a | b; } -enum ItemPosition { - kItemPositionAuto, - kItemPositionNormal, - kItemPositionStretch, - kItemPositionBaseline, - kItemPositionLastBaseline, - kItemPositionCenter, - kItemPositionStart, - kItemPositionEnd, - kItemPositionSelfStart, - kItemPositionSelfEnd, - kItemPositionFlexStart, - kItemPositionFlexEnd, - kItemPositionLeft, - kItemPositionRight +enum class ItemPosition : unsigned { + kAuto, + kNormal, + kStretch, + kBaseline, + kLastBaseline, + kCenter, + kStart, + kEnd, + kSelfStart, + kSelfEnd, + kFlexStart, + kFlexEnd, + kLeft, + kRight }; enum class OverflowAlignment : unsigned { kDefault, kUnsafe, kSafe }; -enum ItemPositionType { kNonLegacyPosition, kLegacyPosition }; +enum class ItemPositionType : unsigned { kNonLegacy, kLegacy }; enum class ContentPosition : unsigned { kNormal,
diff --git a/third_party/WebKit/Source/core/style/StyleSelfAlignmentData.h b/third_party/WebKit/Source/core/style/StyleSelfAlignmentData.h index 97fbbdc..794cf86 100644 --- a/third_party/WebKit/Source/core/style/StyleSelfAlignmentData.h +++ b/third_party/WebKit/Source/core/style/StyleSelfAlignmentData.h
@@ -18,16 +18,19 @@ // items}, justify-{self, items}. // [ <self-position> && <overflow-position>? ] | [ legacy && [ left | right | // center ] ] - StyleSelfAlignmentData(ItemPosition position, - OverflowAlignment overflow, - ItemPositionType position_type = kNonLegacyPosition) - : position_(position), - position_type_(position_type), + StyleSelfAlignmentData( + ItemPosition position, + OverflowAlignment overflow, + ItemPositionType position_type = ItemPositionType::kNonLegacy) + : position_(static_cast<unsigned>(position)), + position_type_(static_cast<unsigned>(position_type)), overflow_(static_cast<unsigned>(overflow)) {} - void SetPosition(ItemPosition position) { position_ = position; } + void SetPosition(ItemPosition position) { + position_ = static_cast<unsigned>(position); + } void SetPositionType(ItemPositionType position_type) { - position_type_ = position_type; + position_type_ = static_cast<unsigned>(position_type); } void SetOverflow(OverflowAlignment overflow) { overflow_ = static_cast<unsigned>(overflow);
diff --git a/third_party/WebKit/Source/devtools/front_end/console/ConsoleViewMessage.js b/third_party/WebKit/Source/devtools/front_end/console/ConsoleViewMessage.js index ff6edce3..4ff8ebb 100644 --- a/third_party/WebKit/Source/devtools/front_end/console/ConsoleViewMessage.js +++ b/third_party/WebKit/Source/devtools/front_end/console/ConsoleViewMessage.js
@@ -577,7 +577,7 @@ * @return {!Element} */ _formatParameterAsObject(obj, includePreview) { - var titleElement = createElement('span'); + var titleElement = createElementWithClass('span', 'console-object'); if (includePreview && obj.preview) { titleElement.classList.add('console-object-preview'); this._previewFormatter.appendObjectPreview(titleElement, obj.preview, false /* isEntry */);
diff --git a/third_party/WebKit/Source/devtools/front_end/console/consoleView.css b/third_party/WebKit/Source/devtools/front_end/console/consoleView.css index bd105f77..a8868d9 100644 --- a/third_party/WebKit/Source/devtools/front_end/console/consoleView.css +++ b/third_party/WebKit/Source/devtools/front_end/console/consoleView.css
@@ -324,7 +324,9 @@ flex-shrink: 0; } -.console-message-text .object-value-string { +.console-message-text .object-value-string, +.console-message-text .object-value-regexp, +.console-message-text .object-value-symbol { white-space: pre-wrap; word-break: break-all; } @@ -385,6 +387,13 @@ vertical-align: baseline; color: inherit; display: inline-block; + overflow-wrap: break-word; + max-width: 100%; +} + +.console-object { + white-space: pre-wrap; + word-break: break-all; } .console-message-stack-trace-toggle {
diff --git a/third_party/WebKit/Source/devtools/front_end/object_ui/RemoteObjectPreviewFormatter.js b/third_party/WebKit/Source/devtools/front_end/object_ui/RemoteObjectPreviewFormatter.js index 2d89471..285b180 100644 --- a/third_party/WebKit/Source/devtools/front_end/object_ui/RemoteObjectPreviewFormatter.js +++ b/third_party/WebKit/Source/devtools/front_end/object_ui/RemoteObjectPreviewFormatter.js
@@ -59,7 +59,7 @@ parentElement.createChild('span', 'object-description').textContent = text + '\u00a0'; } - var propertiesElement = parentElement.createChild('span', 'object-properties-preview source-code'); + var propertiesElement = parentElement.createChild('span', 'object-properties-preview'); propertiesElement.createTextChild(isArrayOrTypedArray ? '[' : '{'); if (preview.entries) this._appendEntriesPreview(propertiesElement, preview);
diff --git a/third_party/WebKit/Source/devtools/front_end/object_ui/objectValue.css b/third_party/WebKit/Source/devtools/front_end/object_ui/objectValue.css index 45c8ff35..6cdc72a7 100644 --- a/third_party/WebKit/Source/devtools/front_end/object_ui/objectValue.css +++ b/third_party/WebKit/Source/devtools/front_end/object_ui/objectValue.css
@@ -91,7 +91,7 @@ color: gray; } -.object-properties-preview { +.value .object-properties-preview { white-space: nowrap; }
diff --git a/tools/mb/README.md b/tools/mb/README.md index 4e73a8e9..6483f0e 100644 --- a/tools/mb/README.md +++ b/tools/mb/README.md
@@ -1,13 +1,19 @@ # MB - The Meta-Build wrapper -MB is a simple wrapper intended to provide a uniform interface to either -GYP or GN, such that users and bots can call one script and not need to -worry about whether a given bot is meant to use GN or GYP. +MB is a simple wrapper around the GN build tool. + +It was originally written as part of the GYP->GN migration, in order to +provide a uniform interface to either GYP or GN, such that users and bots +can call one script and not need to worry about whether a given bot was +meant to use GN or GYP. + +It eventually grew additional functionality and is now still used even +though everything is GN-only. It supports two main functions: -1. "gen" - the main `gyp_chromium` / `gn gen` invocation that generates the - Ninja files needed for the build. +1. "gen" - the main `gn gen` invocation that generates the Ninja files + needed for the build. 2. "analyze" - the step that takes a list of modified files and a list of desired targets and reports which targets will need to be rebuilt.
diff --git a/tools/mb/docs/design_spec.md b/tools/mb/docs/design_spec.md index fb202da..7836d8ec 100644 --- a/tools/mb/docs/design_spec.md +++ b/tools/mb/docs/design_spec.md
@@ -4,21 +4,22 @@ ## Intro -MB is intended to address two major aspects of the GYP -> GN transition -for Chromium: +MB was originally intended to address two major aspects of the GYP -> GN +transition for Chromium: 1. "bot toggling" - make it so that we can easily flip a given bot back and forth between GN and GYP. 2. "bot configuration" - provide a single source of truth for all of - the different configurations (os/arch/`gyp_define` combinations) of + the different configurations (os/arch/`gn_args` combinations) of Chromium that are supported. -MB must handle at least the `gen` and `analyze` steps on the bots, i.e., -we need to wrap both the `gyp_chromium` invocation to generate the -Ninja files, and the `analyze` step that takes a list of modified files -and a list of targets to build and returns which targets are affected by -the files. +Now that everything is using GN, only the second purpose is really relevant, +but it's still important. MB must handle at least the `gen` and `analyze` +steps on the bots, i.e., we need to wrap both the `gn gen` invocation to +generate the Ninja files, and the `analyze` step that takes a list of +modified files and a list of targets to build and returns which targets +are affected by the files. For more information on how to actually use MB, see [the user guide](user_guide.md). @@ -26,7 +27,7 @@ ## Design MB is intended to be as simple as possible, and to defer as much work as -possible to GN or GYP. It should live as a very simple Python wrapper +possible to GN. It should live as a very simple Python wrapper that offers little in the way of surprises. ### Command line @@ -40,16 +41,12 @@ `mb` will first look for a bot config file in a set of different locations (initially just in //ios/build/bots). Bot config files are JSON files that -contain keys for 'GYP_DEFINES' (a list of strings that will be joined together -with spaces and passed to GYP, or a dict that will be similarly converted), -'gn_args' (a list of strings that will be joined together), and an -'mb_type' field that says whether to use GN or GYP. Bot config files -require the full list of settings to be given explicitly. +contain keys for 'gn_args' (a list of strings that will be joined together). +Bot config files require the full list of settings to be given explicitly. If no matching bot config file is found, `mb` looks in the -`//tools/mb/mb_config.pyl` config file to determine whether to use GYP or GN -for a particular build directory, and what set of flags (`GYP_DEFINES` or `gn -args`) to use. +`//tools/mb/mb_config.pyl` config file to determine what set of flags +(`gn args`) to use. A config can either be specified directly (useful for testing) or by specifying the master name and builder name (useful on the bots so that they do not need @@ -64,10 +61,6 @@ The way analyze works can be subtle and complicated (see below). -Since the interface basically mirrors the way the "analyze" step on the bots -invokes `gyp_chromium` today, when the config is found to be a gyp config, -the arguments are passed straight through. - It implements the equivalent functionality in GN by calling `gn refs [list of files] --type=executable --all --as=output` and filtering the output to match the list of targets. @@ -110,16 +103,15 @@ you need to build base_unittests. For others (like the telemetry and layout tests), you might need to build several executables in order to run the tests, and that mapping might best be captured by a *meta* - target (a GN group or a GYP 'none' target like `webkit_tests`) that - depends on the right list of files. Because the GN and GYP files know - nothing about test steps, we have to have some way of mapping back - and forth between test steps and build targets. That mapping - is *not* currently available to MB (or GN or GYP), and so we have to - enough information to make it possible for the caller to do the mapping. + target (a GN group like `webkit_tests`) that depends on the right list + of files. Because the BUILD.gn files know nothing about test steps, we + have to have some way of mapping back and forth between test steps and + build targets. That mapping is *not* currently available to MB (or GN), + and so we have to provide enough information to make it possible for + the caller to do the mapping. 3. We might also want to know when test targets are affected by data files that aren't compiled (python scripts, or the layout tests themselves). - There's no good way to do this in GYP, but GN supports this. 4. We also want to ensure that particular targets still compile even if they are not actually tested; consider testing the installers themselves, or @@ -137,9 +129,9 @@ 6. As noted above, in the ideal case we actually have enough resources and things are fast enough that we can afford to build everything affected by a patch, but listing every possible target explicitly would be painful. The - GYP and GN Ninja generators provide an 'all' target that captures (nearly, + GN Ninja generator provides an 'all' target that captures (nearly, see [crbug.com/503241](crbug.com/503241)) everything, but unfortunately - neither GN nor GYP actually represents 'all' as a meta target in the build + GN doesn't actually represent 'all' as a meta target in the build graph, so we will need to write code to handle that specially. 7. In some cases, we will not be able to correctly analyze the build graph to @@ -216,7 +208,7 @@ build, or that there were no affected test targets as appropriate. Note that passing no arguments to Ninja is equivalent to passing -`all` to Ninja (at least given how GN and GYP work); however, we +`all` to Ninja (at least given how GN works); however, we don't want to take advantage of this in most cases because we don't actually want to build every out of date target, only the targets potentially affected by the files. One could try to indicate @@ -225,7 +217,7 @@ confusing, and adding a new field for this seems unwarranted at this time. There is an "error" field in case something goes wrong (like the -empty file list case, above, or an internal error in MB/GYP/GN). The +empty file list case, above, or an internal error in MB/GN). The analyze code should also return an error code to the shell if appropriate to indicate that the command failed. @@ -350,8 +342,7 @@ The first issue is whether or not this should exist as a script in Chromium at all; an alternative would be to simply change the bot -configurations to know whether to use GYP or GN, and which flags to -pass. +configurations to know which flags to pass. That would certainly work, but experience over the past two years suggests a few things: @@ -373,23 +364,12 @@ ### Why not have MB be smarter about de-duping flags? This just adds complexity to the MB implementation, and duplicates logic -that GYP and GN already have to support anyway; in particular, it might -require MB to know how to parse GYP and GN values. The belief is that +that GN already has to support anyway; in particular, it might +require MB to know how to parse GN values. The belief is that if MB does *not* do this, it will lead to fewer surprises. It will not be hard to change this if need be. -### Integration w/ gclient runhooks - -On the bots, we will disable `gyp_chromium` as part of runhooks (using -`GYP_CHROMIUM_NO_ACTION=1`), so that mb shows up as a separate step. - -At the moment, we expect most developers to either continue to use -`gyp_chromium` in runhooks or to disable at as above if they have no -use for GYP at all. We may revisit how this works once we encourage more -people to use GN full-time (i.e., we might take `gyp_chromium` out of -runhooks altogether). - ### Config per flag set or config per (os/arch/flag set)? Currently, mb_config.pyl does not specify the host_os, target_os, host_cpu, or @@ -410,17 +390,15 @@ ### Non-goals -* MB is not intended to replace direct invocation of GN or GYP for +* MB is not intended to replace direct invocation of GN for complicated build scenarios (a.k.a. Chrome OS), where multiple flags need to be set to user-defined paths for specific toolchains (e.g., where Chrome OS needs to specify specific board types and compilers). * MB is not intended at this time to be something developers use frequently, - or to add a lot of features to. We hope to be able to get rid of it once - the GYP->GN migration is done, and so we should not add things for - developers that can't easily be added to GN itself. + or to add a lot of features to. We hope to be able to get rid of it + eventually. * MB is not intended to replace the - [CR tool](https://code.google.com/p/chromium/wiki/CRUserManual). Not - only is it only intended to replace the gyp\_chromium part of `'gclient - runhooks'`, it is not really meant as a developer-facing tool. + [CR tool](https://code.google.com/p/chromium/wiki/CRUserManual), and + it is not really meant as a developer-facing tool.
diff --git a/tools/mb/docs/user_guide.md b/tools/mb/docs/user_guide.md index a7d72c8..ee653040 100644 --- a/tools/mb/docs/user_guide.md +++ b/tools/mb/docs/user_guide.md
@@ -4,8 +4,8 @@ ## Introduction -`mb` is a simple python wrapper around the GYP and GN meta-build tools to -be used as part of the GYP->GN migration. +`mb` is a simple python wrapper GN meta-build tool; it was originally +written as part of the GYP->GN migration. It is intended to be used by bots to make it easier to manage the configuration each bot builds (i.e., the configurations can be changed from chromium @@ -45,7 +45,7 @@ reflect the stuff we might want to build *in addition to* the list passed in `test_targets`. Targets in this list will be treated specially, in the following way: if a given target is a "meta" - (GN: group, GYP: none) target like 'blink_tests' or or even the + (GN: group) target like 'blink_tests' or or even the ninja-specific 'all' target, then only the *dependencies* of the target that are affected by the modified files will be rebuilt (not the target itself, which might also cause unaffected dependencies @@ -93,18 +93,11 @@ The `-b/--builder`, `-c/--config`, `-f/--config-file`, `-m/--master`, `-q/--quiet`, and `-v/--verbose` flags work as documented for `mb gen`. -### `mb audit` - -`mb audit` is used to track the progress of the GYP->GN migration. You can -use it to check a single master, or all the masters we care about. See -`mb help audit` for more details (most people are not expected to care about -this). - ### `mb gen` -`mb gen` is responsible for generating the Ninja files by invoking either GYP -or GN as appropriate. It takes arguments to specify a build config and -a directory, then runs GYP or GN as appropriate: +`mb gen` is responsible for generating the Ninja files by invoking GN with +the right sets of build args for the given bot. It takes arguments to +specify a build config and a directory, then runs GN as appropriate: ``` % mb gen -m tryserver.chromium.linux -b linux_rel //out/Release @@ -133,12 +126,7 @@ If the build config will use the Goma distributed-build system, you can pass the path to your Goma client in the `-g/--goma-dir` flag, and it will be -incorporated into the appropriate flags for GYP or GN as needed. - -If gen ends up using GYP, the path must have a valid GYP configuration as the -last component of the path (i.e., specify `//out/Release_x64`, not `//out`). -The gyp script defaults to `//build/gyp_chromium`, but can be overridden with -the `--gyp-script` flag, e.g. `--gyp-script=gypfiles/gyp_v8`. +incorporated into the appropriate flags for GN as needed. ### `mb help` @@ -186,7 +174,7 @@ `mb gen` is also responsible for generating the `.isolate` and `.isolated.gen.json` files needed to run test executables through swarming -in a GN build (in a GYP build, this is done as part of the compile step). +in a GN build. If you wish to generate the isolate files, pass `mb gen` the `--swarming-targets-file` command line argument; that arg should be a path @@ -210,7 +198,7 @@ supported build configurations for Chromium. Generally speaking, you should never need to (or want to) build a configuration that isn't listed here, and so by using the configs in this file you can avoid -having to juggle long lists of GYP_DEFINES and gn args by hand. +having to juggle long lists of gn args by hand. `mb_config.pyl` is structured as a file containing a single PYthon Literal expression: a dictionary with three main keys, `masters`, `configs` and @@ -239,49 +227,38 @@ Each mixin value is itself a dictionary that contains one or more of the following keys: - * `gyp_crosscompile`: a boolean; if true, GYP_CROSSCOMPILE=1 is set in - the environment and passed to GYP. - * `gyp_defines`: a string containing a list of GYP_DEFINES. * `gn_args`: a string containing a list of values passed to gn --args. * `mixins`: a list of other mixins that should be included. - * `type`: a string with either the value `gyp` or `gn`; - setting this indicates which meta-build tool to use. When `mb gen` or `mb analyze` executes, it takes a config name, looks it up in the 'configs' dict, and then does a left-to-right expansion of the -mixins; gyp_defines and gn_args values are concatenated, and the type values -override each other. +mixins; gn_args values are concatenated. For example, if you had: ``` { 'configs`: { - 'linux_release_trybot': ['gyp_release', 'trybot'], + 'linux_release_trybot': ['gn_release', 'trybot'], 'gn_shared_debug': None, } 'mixins': { 'bot': { - 'gyp_defines': 'use_goma=1 dcheck_always_on=0', 'gn_args': 'use_goma=true dcheck_always_on=false', }, 'debug': { 'gn_args': 'is_debug=true', }, - 'gn': {'type': 'gn'}, - 'gyp_release': { + 'gn_release': { 'mixins': ['release'], - 'type': 'gyp', }, 'release': { 'gn_args': 'is_debug=false', } 'shared': { 'gn_args': 'is_component_build=true', - 'gyp_defines': 'component=shared_library', }, 'trybot': { - 'gyp_defines': 'dcheck_always_on=1', 'gn_args': 'dcheck_always_on=true', } } @@ -289,11 +266,10 @@ ``` and you ran `mb gen -c linux_release_trybot //out/Release`, it would -translate into a call to `gyp_chromium -G Release` with `GYP_DEFINES` set to -`"use_goma=true dcheck_always_on=false dcheck_always_on=true"`. +translate into a call to `gn --args="use_goma=true dcheck_always_on=false dcheck_always_on=true"`. (From that you can see that mb is intentionally dumb and does not -attempt to de-dup the flags, it lets gyp do that). +attempt to de-dup the flags, it lets GN do that). ## Debugging MB
diff --git a/tools/mb/mb.py b/tools/mb/mb.py index 92edd67..df21410 100755 --- a/tools/mb/mb.py +++ b/tools/mb/mb.py
@@ -3,9 +3,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -"""MB - the Meta-Build wrapper around GYP and GN +"""MB - the Meta-Build wrapper around GN -MB is a wrapper script for GYP and GN that can be used to generate build files +MB is a wrapper script for GN that can be used to generate build files for sets of canned configurations and analyze them. """ @@ -95,16 +95,10 @@ '(default is %(default)s)') subp.add_argument('-g', '--goma-dir', help='path to goma directory') - subp.add_argument('--gyp-script', metavar='PATH', - default=self.PathJoin('build', 'gyp_chromium'), - help='path to gyp script relative to project root ' - '(default is %(default)s)') subp.add_argument('--android-version-code', - help='Sets GN arg android_default_version_code and ' - 'GYP_DEFINE app_manifest_version_code') + help='Sets GN arg android_default_version_code') subp.add_argument('--android-version-name', - help='Sets GN arg android_default_version_name and ' - 'GYP_DEFINE app_manifest_version_name') + help='Sets GN arg android_default_version_name') subp.add_argument('-n', '--dryrun', action='store_true', help='Do a dry run (i.e., do nothing, just print ' 'the commands that will run)') @@ -212,26 +206,6 @@ help='path to config file (default is %(default)s)') subp.set_defaults(func=self.CmdValidate) - subp = subps.add_parser('audit', - help='Audit the config file to track progress') - subp.add_argument('-f', '--config-file', metavar='PATH', - default=self.default_config, - help='path to config file (default is %(default)s)') - subp.add_argument('-i', '--internal', action='store_true', - help='check internal masters also') - subp.add_argument('-m', '--master', action='append', - help='master to audit (default is all non-internal ' - 'masters in file)') - subp.add_argument('-u', '--url-template', action='store', - default='https://build.chromium.org/p/' - '{master}/json/builders', - help='URL scheme for JSON APIs to buildbot ' - '(default: %(default)s) ') - subp.add_argument('-c', '--check-compile', action='store_true', - help='check whether tbd and master-only bots actually' - ' do compiles') - subp.set_defaults(func=self.CmdAudit) - subp = subps.add_parser('gerrit-buildbucket-config', help='Print buildbucket.config for gerrit ' '(see MB user guide)') @@ -267,11 +241,7 @@ def CmdAnalyze(self): vals = self.Lookup() - self.ClobberIfNeeded(vals) - if vals['type'] == 'gn': - return self.RunGNAnalyze(vals) - else: - return self.RunGYPAnalyze(vals) + return self.RunGNAnalyze(vals) def CmdExport(self): self.ReadConfigFile() @@ -303,11 +273,7 @@ def CmdGen(self): vals = self.Lookup() - self.ClobberIfNeeded(vals) - if vals['type'] == 'gn': - return self.RunGNGen(vals) - else: - return self.RunGYPGen(vals) + return self.RunGNGen(vals) def CmdHelp(self): if self.args.subcommand: @@ -319,21 +285,14 @@ vals = self.GetConfig() if not vals: return 1 - - if vals['type'] == 'gn': - return self.RunGNIsolate(vals) - else: - return self.Build('%s_run' % self.args.target[0]) + return self.RunGNIsolate(vals) def CmdLookup(self): vals = self.Lookup() - if vals['type'] == 'gn': - cmd = self.GNCmd('gen', '_path_') - gn_args = self.GNArgs(vals) - self.Print('\nWriting """\\\n%s""" to _path_/args.gn.\n' % gn_args) - env = None - else: - cmd, env = self.GYPCmd('_path_', vals) + cmd = self.GNCmd('gen', '_path_') + gn_args = self.GNArgs(vals) + self.Print('\nWriting """\\\n%s""" to _path_/args.gn.\n' % gn_args) + env = None self.PrintCmd(cmd, env) return 0 @@ -346,18 +305,13 @@ build_dir = self.args.path[0] target = self.args.target[0] - if vals['type'] == 'gn': - if self.args.build: - ret = self.Build(target) - if ret: - return ret - ret = self.RunGNIsolate(vals) + if self.args.build: + ret = self.Build(target) if ret: return ret - else: - ret = self.Build('%s_run' % target) - if ret: - return ret + ret = self.RunGNIsolate(vals) + if ret: + return ret cmd = [ self.executable, @@ -476,154 +430,26 @@ self.Print('mb config file %s looks ok.' % self.args.config_file) return 0 - def CmdAudit(self): - """Track the progress of the GYP->GN migration on the bots.""" - - # First, make sure the config file is okay, but don't print anything - # if it is (it will throw an error if it isn't). - self.CmdValidate(print_ok=False) - - stats = OrderedDict() - STAT_MASTER_ONLY = 'Master only' - STAT_CONFIG_ONLY = 'Config only' - STAT_TBD = 'Still TBD' - STAT_GYP = 'Still GYP' - STAT_DONE = 'Done (on GN)' - stats[STAT_MASTER_ONLY] = 0 - stats[STAT_CONFIG_ONLY] = 0 - stats[STAT_TBD] = 0 - stats[STAT_GYP] = 0 - stats[STAT_DONE] = 0 - - def PrintBuilders(heading, builders, notes): - stats.setdefault(heading, 0) - stats[heading] += len(builders) - if builders: - self.Print(' %s:' % heading) - for builder in sorted(builders): - self.Print(' %s%s' % (builder, notes[builder])) - - self.ReadConfigFile() - - masters = self.args.master or self.masters - for master in sorted(masters): - url = self.args.url_template.replace('{master}', master) - - self.Print('Auditing %s' % master) - - MASTERS_TO_SKIP = ( - 'client.skia', - 'client.v8.fyi', - 'tryserver.v8', - ) - if master in MASTERS_TO_SKIP: - # Skip these bots because converting them is the responsibility of - # those teams and out of scope for the Chromium migration to GN. - self.Print(' Skipped (out of scope)') - self.Print('') - continue - - INTERNAL_MASTERS = ('official.desktop', 'official.desktop.continuous', - 'internal.client.kitchensync') - if master in INTERNAL_MASTERS and not self.args.internal: - # Skip these because the servers aren't accessible by default ... - self.Print(' Skipped (internal)') - self.Print('') - continue - - try: - # Fetch the /builders contents from the buildbot master. The - # keys of the dict are the builder names themselves. - json_contents = self.Fetch(url) - d = json.loads(json_contents) - except Exception as e: - self.Print(str(e)) - return 1 - - config_builders = set(self.masters[master]) - master_builders = set(d.keys()) - both = master_builders & config_builders - master_only = master_builders - config_builders - config_only = config_builders - master_builders - tbd = set() - gyp = set() - done = set() - notes = {builder: '' for builder in config_builders | master_builders} - - for builder in both: - config = self.masters[master][builder] - if config == 'tbd': - tbd.add(builder) - elif isinstance(config, dict): - vals = self.FlattenConfig(config.values()[0]) - if vals['type'] == 'gyp': - gyp.add(builder) - else: - done.add(builder) - elif config.startswith('//'): - done.add(builder) - else: - vals = self.FlattenConfig(config) - if vals['type'] == 'gyp': - gyp.add(builder) - else: - done.add(builder) - - if self.args.check_compile and (tbd or master_only): - either = tbd | master_only - for builder in either: - notes[builder] = ' (' + self.CheckCompile(master, builder) +')' - - if master_only or config_only or tbd or gyp: - PrintBuilders(STAT_MASTER_ONLY, master_only, notes) - PrintBuilders(STAT_CONFIG_ONLY, config_only, notes) - PrintBuilders(STAT_TBD, tbd, notes) - PrintBuilders(STAT_GYP, gyp, notes) - else: - self.Print(' All GN!') - - stats[STAT_DONE] += len(done) - - self.Print('') - - fmt = '{:<27} {:>4}' - self.Print(fmt.format('Totals', str(sum(int(v) for v in stats.values())))) - self.Print(fmt.format('-' * 27, '----')) - for stat, count in stats.items(): - self.Print(fmt.format(stat, str(count))) - - return 0 - def GetConfig(self): build_dir = self.args.path[0] vals = self.DefaultVals() if self.args.builder or self.args.master or self.args.config: vals = self.Lookup() - if vals['type'] == 'gn': - # Re-run gn gen in order to ensure the config is consistent with the - # build dir. - self.RunGNGen(vals) + # Re-run gn gen in order to ensure the config is consistent with the + # build dir. + self.RunGNGen(vals) return vals - mb_type_path = self.PathJoin(self.ToAbsPath(build_dir), 'mb_type') - if not self.Exists(mb_type_path): - toolchain_path = self.PathJoin(self.ToAbsPath(build_dir), - 'toolchain.ninja') - if not self.Exists(toolchain_path): - self.Print('Must either specify a path to an existing GN build dir ' - 'or pass in a -m/-b pair or a -c flag to specify the ' - 'configuration') - return {} - else: - mb_type = 'gn' - else: - mb_type = self.ReadFile(mb_type_path).strip() + toolchain_path = self.PathJoin(self.ToAbsPath(build_dir), + 'toolchain.ninja') + if not self.Exists(toolchain_path): + self.Print('Must either specify a path to an existing GN build dir ' + 'or pass in a -m/-b pair or a -c flag to specify the ' + 'configuration') + return {} - if mb_type == 'gn': - vals['gn_args'] = self.GNArgsFromDir(build_dir) - vals['type'] = mb_type - + vals['gn_args'] = self.GNArgsFromDir(build_dir) return vals def GNArgsFromDir(self, build_dir): @@ -655,14 +481,6 @@ raise MBErr('Config "%s" not found in %s' % (config, self.args.config_file)) vals = self.FlattenConfig(config) - - # Do some basic sanity checking on the config so that we - # don't have to do this in every caller. - if 'type' not in vals: - vals['type'] = 'gn' - assert vals['type'] in ('gn', 'gyp'), ( - 'Unknown meta-build type "%s"' % vals['gn_args']) - return vals def ReadIOSBotConfig(self): @@ -674,17 +492,10 @@ return {} contents = json.loads(self.ReadFile(path)) - gyp_vals = contents.get('GYP_DEFINES', {}) - if isinstance(gyp_vals, dict): - gyp_defines = ' '.join('%s=%s' % (k, v) for k, v in gyp_vals.items()) - else: - gyp_defines = ' '.join(gyp_vals) gn_args = ' '.join(contents.get('gn_args', [])) vals = self.DefaultVals() vals['gn_args'] = gn_args - vals['gyp_defines'] = gyp_defines - vals['type'] = contents.get('mb_type', 'gn') return vals def ReadConfigFile(self): @@ -761,9 +572,6 @@ 'args_file': '', 'cros_passthrough': False, 'gn_args': '', - 'gyp_defines': '', - 'gyp_crosscompile': False, - 'type': 'gn', } def FlattenMixins(self, mixins, vals, visited): @@ -787,50 +595,11 @@ vals['gn_args'] += ' ' + mixin_vals['gn_args'] else: vals['gn_args'] = mixin_vals['gn_args'] - if 'gyp_crosscompile' in mixin_vals: - vals['gyp_crosscompile'] = mixin_vals['gyp_crosscompile'] - if 'gyp_defines' in mixin_vals: - if vals['gyp_defines']: - vals['gyp_defines'] += ' ' + mixin_vals['gyp_defines'] - else: - vals['gyp_defines'] = mixin_vals['gyp_defines'] - if 'type' in mixin_vals: - vals['type'] = mixin_vals['type'] if 'mixins' in mixin_vals: self.FlattenMixins(mixin_vals['mixins'], vals, visited) return vals - def ClobberIfNeeded(self, vals): - path = self.args.path[0] - build_dir = self.ToAbsPath(path) - mb_type_path = self.PathJoin(build_dir, 'mb_type') - needs_clobber = False - new_mb_type = vals['type'] - if self.Exists(build_dir): - if self.Exists(mb_type_path): - old_mb_type = self.ReadFile(mb_type_path) - if old_mb_type != new_mb_type: - self.Print("Build type mismatch: was %s, will be %s, clobbering %s" % - (old_mb_type, new_mb_type, path)) - needs_clobber = True - else: - # There is no 'mb_type' file in the build directory, so this probably - # means that the prior build(s) were not done through mb, and we - # have no idea if this was a GYP build or a GN build. Clobber it - # to be safe. - self.Print("%s/mb_type missing, clobbering to be safe" % path) - needs_clobber = True - - if self.args.dryrun: - return - - if needs_clobber: - self.RemoveDirectory(build_dir) - - self.MaybeMakeDirectory(build_dir) - self.WriteFile(mb_type_path, new_mb_type) - def RunGNGen(self, vals, compute_grit_inputs_for_analyze=False): build_dir = self.args.path[0] @@ -1044,38 +813,6 @@ gn_args = ('import("%s")\n' % vals['args_file']) + gn_args return gn_args - def RunGYPGen(self, vals): - path = self.args.path[0] - - output_dir = self.ParseGYPConfigPath(path) - cmd, env = self.GYPCmd(output_dir, vals) - ret, _, _ = self.Run(cmd, env=env) - return ret - - def RunGYPAnalyze(self, vals): - output_dir = self.ParseGYPConfigPath(self.args.path[0]) - if self.args.verbose: - inp = self.ReadInputJSON(['files', 'test_targets', - 'additional_compile_targets']) - self.Print() - self.Print('analyze input:') - self.PrintJSON(inp) - self.Print() - - cmd, env = self.GYPCmd(output_dir, vals) - cmd.extend(['-f', 'analyzer', - '-G', 'config_path=%s' % self.args.input_path[0], - '-G', 'analyzer_output_path=%s' % self.args.output_path[0]]) - ret, _, _ = self.Run(cmd, env=env) - if not ret and self.args.verbose: - outp = json.loads(self.ReadFile(self.args.output_path[0])) - self.Print() - self.Print('analyze output:') - self.PrintJSON(outp) - self.Print() - - return ret - def GetIsolateCommand(self, target, vals): isolate_map = self.ReadIsolateMap() @@ -1178,86 +915,6 @@ return path[2:].replace('/', self.sep) return self.RelPath(path, self.chromium_src_dir) - def ParseGYPConfigPath(self, path): - rpath = self.ToSrcRelPath(path) - output_dir, _, _ = rpath.rpartition(self.sep) - return output_dir - - def GYPCmd(self, output_dir, vals): - if vals['cros_passthrough']: - if not 'GYP_DEFINES' in os.environ: - raise MBErr('MB is expecting GYP_DEFINES to be in the environment') - gyp_defines = os.environ['GYP_DEFINES'] - if not 'chromeos=1' in gyp_defines: - raise MBErr('GYP_DEFINES is missing chromeos=1: (GYP_DEFINES=%s)' % - gyp_defines) - else: - gyp_defines = vals['gyp_defines'] - - goma_dir = self.args.goma_dir - - # GYP uses shlex.split() to split the gyp defines into separate arguments, - # so we can support backslashes and and spaces in arguments by quoting - # them, even on Windows, where this normally wouldn't work. - if goma_dir and ('\\' in goma_dir or ' ' in goma_dir): - goma_dir = "'%s'" % goma_dir - - if goma_dir: - gyp_defines += ' gomadir=%s' % goma_dir - - android_version_code = self.args.android_version_code - if android_version_code: - gyp_defines += ' app_manifest_version_code=%s' % android_version_code - - android_version_name = self.args.android_version_name - if android_version_name: - gyp_defines += ' app_manifest_version_name=%s' % android_version_name - - cmd = [ - self.executable, - self.args.gyp_script, - '-G', - 'output_dir=' + output_dir, - ] - - # Ensure that we have an environment that only contains - # the exact values of the GYP variables we need. - env = os.environ.copy() - - # This is a terrible hack to work around the fact that - # //tools/clang/scripts/update.py is invoked by GYP and GN but - # currently relies on an environment variable to figure out - # what revision to embed in the command line #defines. - # For GN, we've made this work via a gn arg that will cause update.py - # to get an additional command line arg, but getting that to work - # via GYP_DEFINES has proven difficult, so we rewrite the GYP_DEFINES - # to get rid of the arg and add the old var in, instead. - # See crbug.com/582737 for more on this. This can hopefully all - # go away with GYP. - m = re.search('llvm_force_head_revision=1\s*', gyp_defines) - if m: - env['LLVM_FORCE_HEAD_REVISION'] = '1' - gyp_defines = gyp_defines.replace(m.group(0), '') - - # This is another terrible hack to work around the fact that - # GYP sets the link concurrency to use via the GYP_LINK_CONCURRENCY - # environment variable, and not via a proper GYP_DEFINE. See - # crbug.com/611491 for more on this. - m = re.search('gyp_link_concurrency=(\d+)(\s*)', gyp_defines) - if m: - env['GYP_LINK_CONCURRENCY'] = m.group(1) - gyp_defines = gyp_defines.replace(m.group(0), '') - - env['GYP_GENERATORS'] = 'ninja' - if 'GYP_CHROMIUM_NO_ACTION' in env: - del env['GYP_CHROMIUM_NO_ACTION'] - if 'GYP_CROSSCOMPILE' in env: - del env['GYP_CROSSCOMPILE'] - env['GYP_DEFINES'] = gyp_defines - if vals['gyp_crosscompile']: - env['GYP_CROSSCOMPILE'] = '1' - return cmd, env - def RunGNAnalyze(self, vals): # Analyze runs before 'gn gen' now, so we need to run gn gen # in order to ensure that we have a build directory. @@ -1459,9 +1116,6 @@ if env and var in env: self.Print('%s%s=%s' % (env_prefix, var, env_quoter(env[var]))) - print_env('GYP_CROSSCOMPILE') - print_env('GYP_DEFINES') - print_env('GYP_LINK_CONCURRENCY') print_env('LLVM_FORCE_HEAD_REVISION') if cmd[0] == self.executable: @@ -1598,7 +1252,6 @@ def QuoteForCmd(arg): # First, escape the arg so that CommandLineToArgvW will parse it properly. - # From //tools/gyp/pylib/gyp/msvs_emulation.py:23. if arg == '' or ' ' in arg or '"' in arg: quote_re = re.compile(r'(\\*)"') arg = '"%s"' % (quote_re.sub(lambda mo: 2 * mo.group(1) + '\\"', arg))
diff --git a/tools/mb/mb_unittest.py b/tools/mb/mb_unittest.py index eaf2b66..0cdc0162 100755 --- a/tools/mb/mb_unittest.py +++ b/tools/mb/mb_unittest.py
@@ -64,8 +64,6 @@ self.files[path] = contents def Call(self, cmd, env=None, buffer_output=True): - if env: - self.cross_compile = env.get('GYP_CROSSCOMPILE') self.calls.append(cmd) if self.cmds: return self.cmds.pop(0) @@ -111,13 +109,10 @@ 'masters': { 'chromium': {}, 'fake_master': { - 'fake_builder': 'gyp_rel_bot', - 'fake_gn_builder': 'gn_rel_bot', - 'fake_gyp_crosscompile_builder': 'gyp_crosscompile', - 'fake_gn_debug_builder': 'gn_debug_goma', - 'fake_gyp_builder': 'gyp_debug', - 'fake_gn_args_bot': '//build/args/bots/fake_master/fake_gn_args_bot.gn', - 'fake_multi_phase': { 'phase_1': 'gn_phase_1', 'phase_2': 'gn_phase_2'}, + 'fake_builder': 'rel_bot', + 'fake_debug_builder': 'debug_goma', + 'fake_args_bot': '//build/args/bots/fake_master/fake_args_bot.gn', + 'fake_multi_phase': { 'phase_1': 'phase_1', 'phase_2': 'phase_2'}, 'fake_args_file': 'args_file_goma', 'fake_args_file_twice': 'args_file_twice', }, @@ -125,38 +120,26 @@ 'configs': { 'args_file_goma': ['args_file', 'goma'], 'args_file_twice': ['args_file', 'args_file'], - 'gyp_rel_bot': ['gyp', 'rel', 'goma'], - 'gn_debug_goma': ['gn', 'debug', 'goma'], - 'gyp_debug': ['gyp', 'debug', 'fake_feature1'], - 'gn_rel_bot': ['gn', 'rel', 'goma'], - 'gyp_crosscompile': ['gyp', 'crosscompile'], - 'gn_phase_1': ['gn', 'phase_1'], - 'gn_phase_2': ['gn', 'phase_2'], + 'rel_bot': ['rel', 'goma', 'fake_feature1'], + 'debug_goma': ['debug', 'goma'], + 'phase_1': ['phase_1'], + 'phase_2': ['phase_2'], }, 'mixins': { - 'crosscompile': { - 'gyp_crosscompile': True, - }, 'fake_feature1': { 'gn_args': 'enable_doom_melon=true', - 'gyp_defines': 'doom_melon=1', }, - 'gyp': {'type': 'gyp'}, - 'gn': {'type': 'gn'}, 'goma': { 'gn_args': 'use_goma=true', - 'gyp_defines': 'goma=1', }, 'args_file': { 'args_file': '//build/args/fake.gn', }, 'phase_1': { 'gn_args': 'phase=1', - 'gyp_args': 'phase=1', }, 'phase_2': { 'gn_args': 'phase=2', - 'gyp_args': 'phase=2', }, 'rel': { 'gn_args': 'is_debug=false', @@ -172,17 +155,16 @@ TEST_BAD_CONFIG = """\ { 'configs': { - 'gn_rel_bot_1': ['gn', 'rel', 'chrome_with_codecs'], - 'gn_rel_bot_2': ['gn', 'rel', 'bad_nested_config'], + 'rel_bot_1': ['rel', 'chrome_with_codecs'], + 'rel_bot_2': ['rel', 'bad_nested_config'], }, 'masters': { 'chromium': { - 'a': 'gn_rel_bot_1', - 'b': 'gn_rel_bot_2', + 'a': 'rel_bot_1', + 'b': 'rel_bot_2', }, }, 'mixins': { - 'gn': {'type': 'gn'}, 'chrome_with_codecs': { 'gn_args': 'proprietary_codecs=true', }, @@ -196,30 +178,6 @@ } """ - -GYP_HACKS_CONFIG = """\ -{ - 'masters': { - 'chromium': {}, - 'fake_master': { - 'fake_builder': 'fake_config', - }, - }, - 'configs': { - 'fake_config': ['fake_mixin'], - }, - 'mixins': { - 'fake_mixin': { - 'type': 'gyp', - 'gn_args': '', - 'gyp_defines': - ('foo=bar llvm_force_head_revision=1 ' - 'gyp_link_concurrency=1 baz=1'), - }, - }, -} -""" - TRYSERVER_CONFIG = """\ { 'masters': { @@ -257,7 +215,7 @@ }, }''') mbw.files.setdefault( - mbw.ToAbsPath('//build/args/bots/fake_master/fake_gn_args_bot.gn'), + mbw.ToAbsPath('//build/args/bots/fake_master/fake_args_bot.gn'), 'is_debug = false\n') if files: for path, contents in files.items(): @@ -277,37 +235,6 @@ self.assertEqual(mbw.err, err) return mbw - def test_clobber(self): - files = { - '/fake_src/out/Debug': None, - '/fake_src/out/Debug/mb_type': None, - } - mbw = self.fake_mbw(files) - - # The first time we run this, the build dir doesn't exist, so no clobber. - self.check(['gen', '-c', 'gn_debug_goma', '//out/Debug'], mbw=mbw, ret=0) - self.assertEqual(mbw.rmdirs, []) - self.assertEqual(mbw.files['/fake_src/out/Debug/mb_type'], 'gn') - - # The second time we run this, the build dir exists and matches, so no - # clobber. - self.check(['gen', '-c', 'gn_debug_goma', '//out/Debug'], mbw=mbw, ret=0) - self.assertEqual(mbw.rmdirs, []) - self.assertEqual(mbw.files['/fake_src/out/Debug/mb_type'], 'gn') - - # Now we switch build types; this should result in a clobber. - self.check(['gen', '-c', 'gyp_debug', '//out/Debug'], mbw=mbw, ret=0) - self.assertEqual(mbw.rmdirs, ['/fake_src/out/Debug']) - self.assertEqual(mbw.files['/fake_src/out/Debug/mb_type'], 'gyp') - - # Now we delete mb_type; this checks the case where the build dir - # exists but wasn't populated by mb; this should also result in a clobber. - del mbw.files['/fake_src/out/Debug/mb_type'] - self.check(['gen', '-c', 'gyp_debug', '//out/Debug'], mbw=mbw, ret=0) - self.assertEqual(mbw.rmdirs, - ['/fake_src/out/Debug', '/fake_src/out/Debug']) - self.assertEqual(mbw.files['/fake_src/out/Debug/mb_type'], 'gyp') - def test_analyze(self): files = {'/tmp/in.json': '''{\ "files": ["foo/foo_unittest.cc"], @@ -323,7 +250,7 @@ mbw = self.fake_mbw(files) mbw.Call = lambda cmd, env=None, buffer_output=True: (0, '', '') - self.check(['analyze', '-c', 'gn_debug_goma', '//out/Default', + self.check(['analyze', '-c', 'debug_goma', '//out/Default', '/tmp/in.json', '/tmp/out.json'], mbw=mbw, ret=0) out = json.loads(mbw.files['/tmp/out.json']) self.assertEqual(out, { @@ -347,7 +274,7 @@ mbw = self.fake_mbw(files) mbw.Call = lambda cmd, env=None, buffer_output=True: (0, '', '') - self.check(['analyze', '-c', 'gn_debug_goma', '//out/Default', + self.check(['analyze', '-c', 'debug_goma', '//out/Default', '/tmp/in.json', '/tmp/out.json'], mbw=mbw, ret=0) out = json.loads(mbw.files['/tmp/out.json']) @@ -370,7 +297,7 @@ mbw = self.fake_mbw(files) mbw.Call = lambda cmd, env=None, buffer_output=True: (0, '', '') - self.check(['analyze', '-c', 'gn_debug_goma', '//out/Default', + self.check(['analyze', '-c', 'debug_goma', '//out/Default', '/tmp/in.json', '/tmp/out.json'], mbw=mbw, ret=0) out = json.loads(mbw.files['/tmp/out.json']) @@ -397,7 +324,7 @@ mbw = self.fake_mbw(files) mbw.Call = lambda cmd, env=None, buffer_output=True: (0, '', '') - self.check(['analyze', '-c', 'gn_debug_goma', '//out/Default', + self.check(['analyze', '-c', 'debug_goma', '//out/Default', '/tmp/in.json', '/tmp/out.json'], mbw=mbw, ret=0) out = json.loads(mbw.files['/tmp/out.json']) @@ -407,9 +334,9 @@ # test_targets and additional_compile_targets. self.assertEqual(['all', 'foo_unittests'], out['compile_targets']) - def test_gn_gen(self): + def test_gen(self): mbw = self.fake_mbw() - self.check(['gen', '-c', 'gn_debug_goma', '//out/Default', '-g', '/goma'], + self.check(['gen', '-c', 'debug_goma', '//out/Default', '-g', '/goma'], mbw=mbw, ret=0) self.assertMultiLineEqual(mbw.files['/fake_src/out/Default/args.gn'], ('goma_dir = "/goma"\n' @@ -422,7 +349,7 @@ mbw.out) mbw = self.fake_mbw(win32=True) - self.check(['gen', '-c', 'gn_debug_goma', '-g', 'c:\\goma', '//out/Debug'], + self.check(['gen', '-c', 'debug_goma', '-g', 'c:\\goma', '//out/Debug'], mbw=mbw, ret=0) self.assertMultiLineEqual(mbw.files['c:\\fake_src\\out\\Debug\\args.gn'], ('goma_dir = "c:\\\\goma"\n' @@ -432,14 +359,14 @@ '--check\n', mbw.out) mbw = self.fake_mbw() - self.check(['gen', '-m', 'fake_master', '-b', 'fake_gn_args_bot', + self.check(['gen', '-m', 'fake_master', '-b', 'fake_args_bot', '//out/Debug'], mbw=mbw, ret=0) self.assertEqual( mbw.files['/fake_src/out/Debug/args.gn'], - 'import("//build/args/bots/fake_master/fake_gn_args_bot.gn")\n') + 'import("//build/args/bots/fake_master/fake_args_bot.gn")\n') - def test_gn_gen_args_file_mixins(self): + def test_gen_args_file_mixins(self): mbw = self.fake_mbw() self.check(['gen', '-m', 'fake_master', '-b', 'fake_args_file', '//out/Debug'], mbw=mbw, ret=0) @@ -453,12 +380,12 @@ self.check(['gen', '-m', 'fake_master', '-b', 'fake_args_file_twice', '//out/Debug'], mbw=mbw, ret=1) - def test_gn_gen_fails(self): + def test_gen_fails(self): mbw = self.fake_mbw() mbw.Call = lambda cmd, env=None, buffer_output=True: (1, '', '') - self.check(['gen', '-c', 'gn_debug_goma', '//out/Default'], mbw=mbw, ret=1) + self.check(['gen', '-c', 'debug_goma', '//out/Default'], mbw=mbw, ret=1) - def test_gn_gen_swarming(self): + def test_gen_swarming(self): files = { '/tmp/swarming_targets': 'base_unittests\n', '/fake_src/testing/buildbot/gn_isolate_map.pyl': ( @@ -474,7 +401,7 @@ } mbw = self.fake_mbw(files) self.check(['gen', - '-c', 'gn_debug_goma', + '-c', 'debug_goma', '--swarming-targets-file', '/tmp/swarming_targets', '//out/Default'], mbw=mbw, ret=0) self.assertIn('/fake_src/out/Default/base_unittests.isolate', @@ -482,7 +409,7 @@ self.assertIn('/fake_src/out/Default/base_unittests.isolated.gen.json', mbw.files) - def test_gn_gen_swarming_script(self): + def test_gen_swarming_script(self): files = { '/tmp/swarming_targets': 'cc_perftests\n', '/fake_src/testing/buildbot/gn_isolate_map.pyl': ( @@ -499,7 +426,7 @@ } mbw = self.fake_mbw(files=files, win32=True) self.check(['gen', - '-c', 'gn_debug_goma', + '-c', 'debug_goma', '--swarming-targets-file', '/tmp/swarming_targets', '--isolate-map-file', '/fake_src/testing/buildbot/gn_isolate_map.pyl', @@ -510,7 +437,7 @@ mbw.files) - def test_gn_isolate(self): + def test_isolate(self): files = { '/fake_src/out/Default/toolchain.ninja': "", '/fake_src/testing/buildbot/gn_isolate_map.pyl': ( @@ -524,7 +451,7 @@ "base_unittests\n" ), } - self.check(['isolate', '-c', 'gn_debug_goma', '//out/Default', + self.check(['isolate', '-c', 'debug_goma', '//out/Default', 'base_unittests'], files=files, ret=0) # test running isolate on an existing build_dir @@ -532,11 +459,10 @@ self.check(['isolate', '//out/Default', 'base_unittests'], files=files, ret=0) - files['/fake_src/out/Default/mb_type'] = 'gn\n' self.check(['isolate', '//out/Default', 'base_unittests'], files=files, ret=0) - def test_gn_run(self): + def test_run(self): files = { '/fake_src/testing/buildbot/gn_isolate_map.pyl': ( "{'base_unittests': {" @@ -549,55 +475,23 @@ "base_unittests\n" ), } - self.check(['run', '-c', 'gn_debug_goma', '//out/Default', + self.check(['run', '-c', 'debug_goma', '//out/Default', 'base_unittests'], files=files, ret=0) - def test_gn_lookup(self): - self.check(['lookup', '-c', 'gn_debug_goma'], ret=0) + def test_lookup(self): + self.check(['lookup', '-c', 'debug_goma'], ret=0) - def test_gn_lookup_goma_dir_expansion(self): - self.check(['lookup', '-c', 'gn_rel_bot', '-g', '/foo'], ret=0, + def test_lookup_goma_dir_expansion(self): + self.check(['lookup', '-c', 'rel_bot', '-g', '/foo'], ret=0, out=('\n' 'Writing """\\\n' + 'enable_doom_melon = true\n' 'goma_dir = "/foo"\n' 'is_debug = false\n' 'use_goma = true\n' '""" to _path_/args.gn.\n\n' '/fake_src/buildtools/linux64/gn gen _path_\n')) - def test_gyp_analyze(self): - mbw = self.check(['analyze', '-c', 'gyp_rel_bot', '//out/Release', - '/tmp/in.json', '/tmp/out.json'], ret=0) - self.assertIn('analyzer', mbw.calls[0]) - - def test_gyp_crosscompile(self): - mbw = self.fake_mbw() - self.check(['gen', '-c', 'gyp_crosscompile', '//out/Release'], - mbw=mbw, ret=0) - self.assertTrue(mbw.cross_compile) - - def test_gyp_gen(self): - self.check(['gen', '-c', 'gyp_rel_bot', '-g', '/goma', '//out/Release'], - ret=0, - out=("GYP_DEFINES='goma=1 gomadir=/goma'\n" - "python build/gyp_chromium -G output_dir=out\n")) - - mbw = self.fake_mbw(win32=True) - self.check(['gen', '-c', 'gyp_rel_bot', '-g', 'c:\\goma', '//out/Release'], - mbw=mbw, ret=0, - out=("set GYP_DEFINES=goma=1 gomadir='c:\\goma'\n" - "python build\\gyp_chromium -G output_dir=out\n")) - - def test_gyp_gen_fails(self): - mbw = self.fake_mbw() - mbw.Call = lambda cmd, env=None, buffer_output=True: (1, '', '') - self.check(['gen', '-c', 'gyp_rel_bot', '//out/Release'], mbw=mbw, ret=1) - - def test_gyp_lookup_goma_dir_expansion(self): - self.check(['lookup', '-c', 'gyp_rel_bot', '-g', '/foo'], ret=0, - out=("GYP_DEFINES='goma=1 gomadir=/foo'\n" - "python build/gyp_chromium -G output_dir=_path_\n")) - def test_help(self): orig_stdout = sys.stdout try: @@ -615,7 +509,7 @@ self.assertIn('Must specify a build --phase', mbw.out) # Check that passing a --phase to a single-phase builder fails. - mbw = self.check(['lookup', '-m', 'fake_master', '-b', 'fake_gn_builder', + mbw = self.check(['lookup', '-m', 'fake_master', '-b', 'fake_builder', '--phase', 'phase_1'], ret=1) self.assertIn('Must not specify a build --phase', mbw.out) @@ -642,16 +536,6 @@ mbw.files[mbw.default_config] = TEST_BAD_CONFIG self.check(['validate'], mbw=mbw, ret=1) - def test_gyp_env_hacks(self): - mbw = self.fake_mbw() - mbw.files[mbw.default_config] = GYP_HACKS_CONFIG - self.check(['lookup', '-c', 'fake_config'], mbw=mbw, - ret=0, - out=("GYP_DEFINES='foo=bar baz=1'\n" - "GYP_LINK_CONCURRENCY=1\n" - "LLVM_FORCE_HEAD_REVISION=1\n" - "python build/gyp_chromium -G output_dir=_path_\n")) - def test_buildbucket(self): mbw = self.fake_mbw() mbw.files[mbw.default_config] = TRYSERVER_CONFIG
diff --git a/tools/metrics/histograms/enums.xml b/tools/metrics/histograms/enums.xml index a1b69e5..b6e0bd9 100644 --- a/tools/metrics/histograms/enums.xml +++ b/tools/metrics/histograms/enums.xml
@@ -30983,6 +30983,34 @@ <int value="3" label="Data parsing failed"/> </enum> +<enum name="OfflinePagesNamespaceEnumeration"> + <int value="0" label="Default">Namespace used as default.</int> + <int value="1" label="Bookmark"> + Namespace used when offline page is saved when bookmarking. + </int> + <int value="2" label="Last_N"> + Namespace used when offline page is saved as last_n page. + </int> + <int value="3" label="Async_loading"> + Namespace used when offline page is saved from save page later on dino page. + </int> + <int value="4" label="Custom_tabs"> + Namespace used when offline page is saved from custom tabs. + </int> + <int value="5" label="Download"> + Namespace used when offline page is saved as downloads. + </int> + <int value="6" label="NTP_suggestions"> + Namespace used when offline page is saved as NTP suggestions. + </int> + <int value="7" label="Suggested_articles"> + Namespace used when offline page is saved as suggested articles. + </int> + <int value="8" label="Browser_actions"> + Namespace used when offline page is saved from browser actions. + </int> +</enum> + <enum name="OfflinePagesOfflineUsage"> <int value="0" label="Not used">Not used at all during whole day.</int> <int value="1" label="Started, but no pages loaded successfully">
diff --git a/tools/metrics/histograms/histograms.xml b/tools/metrics/histograms/histograms.xml index 625138d..1efde27 100644 --- a/tools/metrics/histograms/histograms.xml +++ b/tools/metrics/histograms/histograms.xml
@@ -38718,6 +38718,9 @@ </histogram> <histogram name="MPArch.RWH_HangMonitorUnresponsive" units="ms"> + <obsolete> + Deprecated 12/2017 due to lack of usage. + </obsolete> <owner>amaralp@chromium.org</owner> <summary> The length of time the renderer is unresponsive according to the hang @@ -53857,6 +53860,15 @@ </summary> </histogram> +<histogram name="OfflinePages.AccessPageCount" + enum="OfflinePagesNamespaceEnumeration"> + <owner>romax@chromium.org</owner> + <summary> + Counts the number of times an offline page is accessed. Events are reported + per offline pages namespace. + </summary> +</histogram> + <histogram name="OfflinePages.AggregatedRequestResult" enum="OfflinePagesAggregatedRequestResult"> <obsolete> @@ -54397,6 +54409,15 @@ </summary> </histogram> +<histogram name="OfflinePages.DeletePageCount" + enum="OfflinePagesNamespaceEnumeration"> + <owner>romax@chromium.org</owner> + <summary> + Counts the number of times an offline page is deleted. Events are reported + per offline pages namespace. + </summary> +</histogram> + <histogram name="OfflinePages.DeletePageResult" enum="OfflinePagesDeletePageResult"> <owner>jianli@chromium.org</owner> @@ -54943,6 +54964,15 @@ </summary> </histogram> +<histogram name="OfflinePages.SavePageCount" + enum="OfflinePagesNamespaceEnumeration"> + <owner>romax@chromium.org</owner> + <summary> + Counts the number of times an offline page is saved. Events are reported per + offline pages namespace. + </summary> +</histogram> + <histogram name="OfflinePages.SavePageResult" enum="OfflinePagesSavePageResult"> <owner>jianli@chromium.org</owner> <summary>Result of saving an offline copy for a page.</summary>