Backed out changeset d64938914b3e (bug 1220928) for perma failures in testAboutHomeVisibility | Waiting for HomePager HISTORY panel.
authorCarsten "Tomcat" Book <cbook@mozilla.com>
Wed, 30 Mar 2016 14:38:23 +0200
changeset 290893 435d12d164aa06b543328d2c7300bd57cc2896f5
parent 290892 52247b54de2a3bfd7ce377ced22fd7e706878712
child 290894 a8cb004e06e7c61c6ca3676e2c0d33773882e702
push id19656
push usergwagner@mozilla.com
push dateMon, 04 Apr 2016 13:43:23 +0000
treeherderb2g-inbound@e99061fde28a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1220928
milestone48.0a1
backs outd64938914b3ed77c22ba4559b01d92907056b438
Backed out changeset d64938914b3e (bug 1220928) for perma failures in testAboutHomeVisibility | Waiting for HomePager HISTORY panel.
mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryAdapter.java
mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryItem.java
mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java
mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryRecyclerView.java
mobile/android/base/moz.build
deleted file mode 100644
--- a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryAdapter.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
- * 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 http://mozilla.org/MPL/2.0/. */
-package org.mozilla.gecko.home;
-
-import android.database.Cursor;
-import android.support.v7.widget.RecyclerView;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import org.mozilla.gecko.R;
-import org.mozilla.gecko.db.RemoteClient;
-
-import java.util.Collections;
-import java.util.List;
-
-public class CombinedHistoryAdapter extends RecyclerView.Adapter<CombinedHistoryItem> {
-    // These ordinal positions are used in CombinedHistoryAdapter as viewType.
-    private enum ItemType {
-        CLIENT, HISTORY
-    }
-
-    private List<RemoteClient> remoteClients = Collections.emptyList();
-    private Cursor historyCursor;
-
-    @Override
-    public CombinedHistoryItem onCreateViewHolder(ViewGroup viewGroup, int viewType) {
-        final LayoutInflater inflater = LayoutInflater.from(viewGroup.getContext());
-        final View view;
-        if (viewType == ItemType.CLIENT.ordinal()) {
-            view = inflater.inflate(R.layout.home_remote_tabs_group, viewGroup, false);
-            return new CombinedHistoryItem.ClientItem(view);
-        } else {
-            view = inflater.inflate(R.layout.home_item_row, viewGroup, false);
-            return new CombinedHistoryItem.HistoryItem(view);
-        }
-    }
-
-    @Override
-    public int getItemViewType(int position) {
-        final int numClients = remoteClients.size();
-        return (position < numClients) ? ItemType.CLIENT.ordinal() : ItemType.HISTORY.ordinal();
-    }
-
-    @Override
-    public int getItemCount() {
-        final int remoteSize = remoteClients.size();
-        final int historySize = historyCursor == null ? 0 : historyCursor.getCount();
-        return remoteSize + historySize;
-    }
-
-    @Override
-    public void onBindViewHolder(CombinedHistoryItem viewHolder, int position) {}
-
-}
deleted file mode 100644
--- a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryItem.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
- * 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 http://mozilla.org/MPL/2.0/. */
-package org.mozilla.gecko.home;
-
-import android.support.v7.widget.RecyclerView;
-import android.view.View;
-
-public abstract class CombinedHistoryItem extends RecyclerView.ViewHolder {
-    public CombinedHistoryItem(View view) {
-        super(view);
-    }
-
-    public static class HistoryItem extends CombinedHistoryItem {
-        public HistoryItem(View view) {
-            super(view);
-        }
-    }
-
-    public static class ClientItem extends CombinedHistoryItem {
-        public ClientItem(View view) {
-            super(view);
-        }
-
-    }
-}
deleted file mode 100644
--- a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java
+++ /dev/null
@@ -1,12 +0,0 @@
-/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
- * 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 http://mozilla.org/MPL/2.0/. */
-
-package org.mozilla.gecko.home;
-
-public class CombinedHistoryPanel extends HomeFragment {
-
-    @Override
-    protected void load() {}
-}
deleted file mode 100644
--- a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryRecyclerView.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
- * 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 http://mozilla.org/MPL/2.0/. */
-
-package org.mozilla.gecko.home;
-
-import android.content.Context;
-import android.support.v7.widget.LinearLayoutManager;
-import android.support.v7.widget.RecyclerView;
-import android.util.AttributeSet;
-import android.view.View;
-import org.mozilla.gecko.widget.RecyclerViewClickSupport;
-
-public class CombinedHistoryRecyclerView extends RecyclerView
-        implements RecyclerViewClickSupport.OnItemClickListener, RecyclerViewClickSupport.OnItemLongClickListener {
-
-    public CombinedHistoryRecyclerView(Context context) {
-        super(context);
-        init(context);
-    }
-
-    public CombinedHistoryRecyclerView(Context context, AttributeSet attributeSet) {
-        super(context, attributeSet);
-        init(context);
-    }
-
-    public CombinedHistoryRecyclerView(Context context, AttributeSet attributeSet, int defStyle) {
-        super(context, attributeSet, defStyle);
-        init(context);
-    }
-
-    private void init(Context context) {
-        LinearLayoutManager layoutManager = new LinearLayoutManager(context);
-        layoutManager.setOrientation(LinearLayoutManager.VERTICAL);
-        setLayoutManager(layoutManager);
-    }
-
-    @Override
-    public void onItemClicked(RecyclerView recyclerView, int position, View v) {}
-
-    @Override
-    public boolean onItemLongClicked(RecyclerView recyclerView, int position, View v) {
-        return showContextMenuForChild(this);
-    }
-}
--- a/mobile/android/base/moz.build
+++ b/mobile/android/base/moz.build
@@ -374,20 +374,16 @@ gbjar.sources += ['java/org/mozilla/geck
     'health/SessionInformation.java',
     'health/StubbedHealthRecorder.java',
     'home/BookmarkFolderView.java',
     'home/BookmarkScreenshotRow.java',
     'home/BookmarksListAdapter.java',
     'home/BookmarksListView.java',
     'home/BookmarksPanel.java',
     'home/BrowserSearch.java',
-    'home/CombinedHistoryAdapter.java',
-    'home/CombinedHistoryItem.java',
-    'home/CombinedHistoryPanel.java',
-    'home/CombinedHistoryRecyclerView.java',
     'home/DynamicPanel.java',
     'home/FramePanelLayout.java',
     'home/HistoryHeaderListCursorAdapter.java',
     'home/HistoryItemAdapter.java',
     'home/HistoryPanel.java',
     'home/HomeAdapter.java',
     'home/HomeBanner.java',
     'home/HomeConfig.java',