diff options
Diffstat (limited to 'src/com/android/tv/menu/MenuRow.java')
-rw-r--r-- | src/com/android/tv/menu/MenuRow.java | 72 |
1 files changed, 22 insertions, 50 deletions
diff --git a/src/com/android/tv/menu/MenuRow.java b/src/com/android/tv/menu/MenuRow.java index 47804f11..8dc12bad 100644 --- a/src/com/android/tv/menu/MenuRow.java +++ b/src/com/android/tv/menu/MenuRow.java @@ -17,13 +17,11 @@ package com.android.tv.menu; import android.content.Context; -import android.view.View; /** - * A base class of the item which will be displayed in the main menu. - * It contains the data such as title to represent a row. - * This is an abstract class and the sub-class could have it's own data for - * the row. + * A base class of the item which will be displayed in the main menu. It contains the data such as + * title to represent a row. This is an abstract class and the sub-class could have it's own data + * for the row. */ public abstract class MenuRow { private final Context mContext; @@ -45,86 +43,60 @@ public abstract class MenuRow { mHeight = context.getResources().getDimensionPixelSize(heightResId); } - /** - * Returns the context. - */ + /** Returns the context. */ protected Context getContext() { return mContext; } - /** - * Returns the menu object. - */ + /** Returns the menu object. */ public Menu getMenu() { return mMenu; } - /** - * Returns the title of this row. - */ + /** Returns the title of this row. */ public String getTitle() { return mTitle; } - /** - * Returns the height of this row. - */ + /** Returns the height of this row. */ public int getHeight() { return mHeight; } - /** - * Sets the menu row view. - */ + /** Sets the menu row view. */ public void setMenuRowView(MenuRowView menuRowView) { mMenuRowView = menuRowView; } - /** - * Returns the menu row view. - */ + /** Returns the menu row view. */ protected MenuRowView getMenuRowView() { return mMenuRowView; } - /** - * Updates the contents in this row. - * This method is called only by the menu when necessary. - */ - abstract public void update(); + /** Updates the contents in this row. This method is called only by the menu when necessary. */ + public abstract void update(); - /** - * Indicates whether this row is shown in the menu. - */ + /** Indicates whether this row is shown in the menu. */ public boolean isVisible() { return true; } /** - * Releases all the resources which need to be released. - * This method is called when the main menu is not available any more. + * Releases all the resources which need to be released. This method is called when the main + * menu is not available any more. */ - public void release() { - } + public void release() {} - /** - * Returns the ID of the layout resource for this row. - */ - abstract public int getLayoutResId(); + /** Returns the ID of the layout resource for this row. */ + public abstract int getLayoutResId(); - /** - * Returns the ID of this row. This ID is used to select the row in the main menu. - */ - abstract public String getId(); + /** Returns the ID of this row. This ID is used to select the row in the main menu. */ + public abstract String getId(); - /** - * This method is called when recent channels are changed. - */ - public void onRecentChannelsChanged() { } + /** This method is called when recent channels are changed. */ + public void onRecentChannelsChanged() {} - /** - * Returns whether to hide the title when the row is selected. - */ + /** Returns whether to hide the title when the row is selected. */ public boolean hideTitleWhenSelected() { return false; } |