Files
brave-core/android/java/res/layout/bookmark_toolbar.xml
T
Artem Samoilenko 8ad7a9dcd3 [Android] Switch bookmarks to use DragReorderableRecyclerViewAdapter
Chromium change:
https://github.com/chromium/chromium/commit/2f7edb22295257d0b90c3e24f8a5f24018885a3e

Switch bookmarks to use DragReorderableRecyclerViewAdapter.
The new adapter extends SimpleRecyclerViewAdapter, bringing the
bookmarks code significantly closer to correct MVC. The SRVA invokes
all of the correct and most narrow RecyclerView.Adapter notifications,
allowing us to drop all explicit #notifyDataSetChanged calls.

There was some problems with preventing flicker on model changes, which
were overcome with #setSupportsChangeAnimations(false) and #updateOrAdd.

This is also the first use case to actually integrate with
DragReorderableRecyclerViewAdapter and some changes were needed.
* We need per-row control over draggability, not just per-type.
* Removed explicit swap impl, as ListModelBase#move is sufficient.

Bug: 1413463
2023-05-15 11:02:36 -04:00

16 lines
723 B
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2023 The Brave Authors. All rights reserved.
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this file,
You can obtain one at https://mozilla.org/MPL/2.0/.
-->
<org.chromium.chrome.browser.bookmarks.BraveBookmarkToolbar
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/bookmark_toolbar"
android:layout_width="match_parent"
android:layout_height="@dimen/toolbar_height_no_shadow"
style="@style/ModernToolbar"
app:popupTheme="@style/ModernToolbarPopupTheme" />