IT. Expert System.

Android Reference

ActionMode


android.view

Class ActionMode



  • public abstract class ActionMode
    extends Object
    Represents a contextual mode of the user interface. Action modes can be used to provide alternative interaction modes and replace parts of the normal UI until finished. Examples of good action modes include text selection and contextual actions.

    Developer Guides

    For information about how to provide contextual actions with ActionMode, read the Menus developer guide.

    • Constructor Detail

      • ActionMode

        public ActionMode()
    • Method Detail

      • setTag

        public void setTag(Object tag)
        Set a tag object associated with this ActionMode.

        Like the tag available to views, this allows applications to associate arbitrary data with an ActionMode for later reference.

        Parameters:
        tag - Tag to associate with this ActionMode
        See Also:
        getTag()
      • getTag

        public Object getTag()
        Retrieve the tag object associated with this ActionMode.

        Like the tag available to views, this allows applications to associate arbitrary data with an ActionMode for later reference.

        Returns:
        Tag associated with this ActionMode
        See Also:
        setTag(Object)
      • setTitle

        public abstract void setTitle(CharSequence title)
        Set the title of the action mode. This method will have no visible effect if a custom view has been set.
        Parameters:
        title - Title string to set
        See Also:
        setTitle(int), setCustomView(View)
      • setTitle

        public abstract void setTitle(int resId)
        Set the title of the action mode. This method will have no visible effect if a custom view has been set.
        Parameters:
        resId - Resource ID of a string to set as the title
        See Also:
        setTitle(CharSequence), setCustomView(View)
      • setSubtitle

        public abstract void setSubtitle(CharSequence subtitle)
        Set the subtitle of the action mode. This method will have no visible effect if a custom view has been set.
        Parameters:
        subtitle - Subtitle string to set
        See Also:
        setSubtitle(int), setCustomView(View)
      • setSubtitle

        public abstract void setSubtitle(int resId)
        Set the subtitle of the action mode. This method will have no visible effect if a custom view has been set.
        Parameters:
        resId - Resource ID of a string to set as the subtitle
        See Also:
        setSubtitle(CharSequence), setCustomView(View)
      • setTitleOptionalHint

        public void setTitleOptionalHint(boolean titleOptional)
        Set whether or not the title/subtitle display for this action mode is optional.

        In many cases the supplied title for an action mode is merely meant to add context and is not strictly required for the action mode to be useful. If the title is optional, the system may choose to hide the title entirely rather than truncate it due to a lack of available space.

        Note that this is merely a hint; the underlying implementation may choose to ignore this setting under some circumstances.

        Parameters:
        titleOptional - true if the title only presents optional information.
      • isTitleOptional

        public boolean isTitleOptional()
        Returns:
        true if this action mode considers the title and subtitle fields as optional. Optional titles may not be displayed to the user.
      • setCustomView

        public abstract void setCustomView(View view)
        Set a custom view for this action mode. The custom view will take the place of the title and subtitle. Useful for things like search boxes.
        Parameters:
        view - Custom view to use in place of the title/subtitle.
        See Also:
        setTitle(CharSequence), setSubtitle(CharSequence)
      • getMenu

        public abstract Menu getMenu()
        Returns the menu of actions that this action mode presents.
        Returns:
        The action mode's menu.
      • getTitle

        public abstract CharSequence getTitle()
        Returns the current title of this action mode.
        Returns:
        Title text
      • getSubtitle

        public abstract CharSequence getSubtitle()
        Returns the current subtitle of this action mode.
        Returns:
        Subtitle text
      • getCustomView

        public abstract View getCustomView()
        Returns the current custom view for this action mode.
        Returns:
        The current custom view
      • isUiFocusable

        public boolean isUiFocusable()
        Returns whether the UI presenting this action mode can take focus or not. This is used by internal components within the framework that would otherwise present an action mode UI that requires focus, such as an EditText as a custom view.
        Returns:
        true if the UI used to show this action mode can take focus


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 659 / . Delta: 0.17821 с