目录搜索
androidManifestManifest.permissionManifest.permission_groupandroid.accessibilityserviceAccessibilityServiceandroid.accountsAccountandroid.appNotificationManagerandroid.bluetoothBluetoothAdapterBluetoothClassBluetoothClass.DeviceBluetoothClass.Device.MajorBluetoothClass.ServiceBluetoothDeviceBluetoothServerSocketBluetoothSocketandroid.contentSharedPreferencesandroid.database.sqliteSQLiteCursorDriverSQLiteOpenHelperandroid.graphicsBitmapandroid.locationLocationListenerGeocoderGpsStatusGpsStatus.ListenerGpsStatus.NmeaListenerGpsSatelliteandroid.mediaAudioFormatAsyncPlayerAudioRecordAudioRecord.OnRecordPositionUpdateListenerThumbnailUtilsAudioManagerandroid.netTrafficStatsMailToLocalSocketandroid.osAsyncTaskAsyncTask.StatusCountDownTimerMessageMessageQueueHandlerThreadandroid.textHtmlandroid.utilJsonWriterandroid.viewContextMenuContextMenu.ContextMenuInfoDisplayViewManagerViewViewStubViewTreeObserverViewParentWindowManagerGestureDetectorGravityMenuInflaterScaleGestureDetectorSoundEffectConstantsandroid.view.inputmethodInputConnectionInputMethodInputMethodSessionBaseInputConnectionInputMethodManagerandroid.widgetAbsListViewAbsListView.LayoutParamsAbsListView.OnScrollListenerAbsListView.RecyclerListenerAbsoluteLayoutAbsoluteLayout.LayoutParamsAbsSeekBarAbsSpinnerAdapterViewAdapterView.AdapterContextMenuInfoAdapterView.OnItemLongClickListenerAdapterView.OnItemSelectedListenerAdapterView.OnItemClickListenerAnalogClockBaseAdapterBaseExpandableListAdapterButtonCheckBoxCheckedTextViewCheckableChronometerChronometer.OnChronometerTickListenerCompoundButtonCompoundButton.OnCheckedChangeListenerCursorAdapterCursorTreeAdapterDatePickerDatePicker.OnDateChangedListenerDialerFilterDigitalClockEditTextFilterFilter.FilterListenerFilter.FilterResultsExpandableListAdapterExpandableListView.OnChildClickListenerExpandableListView.OnGroupClickListenerExpandableListView.OnGroupCollapseListenerExpandableListView.OnGroupExpandListenerFilterableGalleryGallery.LayoutParamsGridViewGridLayoutGridLayout.AlignmentRadioGroupImageViewImageView.ScaleTypeHorizontalScrollViewImageButtonImageSwitcherFilterQueryProviderListAdapterListViewMediaControllerMultiAutoCompleteTextViewMultiAutoCompleteTextView.CommaTokenizerMultiAutoCompleteTextView.TokenizerQuickContactBadgeRadioButtonRatingBarRatingBar.OnRatingBarChangeListenerRelativeLayoutRemoteViewsResourceCursorAdapterResourceCursorTreeAdapterScrollerScrollViewSearchViewSearchView.OnCloseListenerSearchView.OnQueryTextListenerSearchView.OnSuggestionListenerSeekBarSeekBar.OnSeekBarChangeListenerSimpleAdapterSimpleAdapter.ViewBinderSimpleCursorAdapterSimpleCursorAdapter.CursorToStringConverterSimpleCursorAdapter.ViewBinderSimpleCursorTreeAdapterSimpleCursorTreeAdapter.ViewBinderSimpleExpandableListAdapterSlidingDrawerSlidingDrawer.OnDrawerCloseListenerSlidingDrawer.OnDrawerOpenListenerSlidingDrawer.OnDrawerScrollListenerSpinnerSpinnerAdapterWrapperListAdapterTabHostTabHost.TabSpecTextViewTimePickerTimePicker.OnTimeChangedListenerToastTableLayoutTableLayout.LayoutParamsTableRowTableRow.LayoutParamsTabWidgetTextSwitcherToggleButtonTwoLineListItemVideoViewViewAnimatorViewFlipperViewSwitcherViewSwitcher.ViewFactoryZoomButtonsControllerZoomButtonsController.OnZoomListenerZoomButtonZoomControlsdalvik.systemDexFile
文字


ZoomButtonsController

版本:Android 2.2 r1

结构

继承关系

public class ZoomButtonsController extends View implements View.OnTouchListener

        

java.lang.Object

android.widget.ZoomButtonsController

 

类概述

ZoomButtonsController处理缩放控件的显示和隐藏并且定位其在相关父视图的位置。他也可以做为缩放控件的容器,允许在缩放控制窗口里面显示一些附加的按钮。

通常情况下,客户端在按下或者移动显示容器需要调用setVisible(ture)方法(不需要调用setVisible(false),来隐藏空间,因为当时间超时,它会自动隐藏),同时,当拥有者不能再进一步缩放的时候,客户端应该调setZoomInEnabled(boolean) setZoomOutEnabled(boolean)

来及时更新。

         如果你需要和自定义视图搭配使用,请在onDetachedFromWindow()方法中调用setVisible(false)

 

构造函数

public ZoomButtonsController (View ownerView)  

ZoomButtonsController的构造函数

参数

ownerView 被缩放控件进行缩放的可视控件, 缩放控件显示将和可视控件保持一致

 

公共方法

public ViewGroup getContainer ()

获取缩放控件的父容器。

客户端可以增加其他的可视控件,和缩放控件一起放到这个容器中

返回

缩放控件的容器,它的布局将和它子控件的布局保持一致

 

public View getZoomControls ()

获取缩放控件的视图

返回

缩放控件视图

 

public boolean isAutoDismissed ()

获取缩放控件是否显示后自动关闭

返回

缩放控件是否显示后自动关闭

 

public boolean isVisible ()

缩放控件是否对用户可视

返回

true 或者false

 

public void setAutoDismissed (boolean autoDismiss)

设置缩放控件是否显示后自动关闭

参数

AutoDismiss   true或者false

 

public void setFocusable (boolean focusable)

设置缩放控件是否获取焦点,如果控件获取焦点,就是可以使用轨迹球和方向键进行操作,否则,只能触摸进行操作

参数

focusable  Truefalse

 

public void setOnZoomListener (ZoomButtonsController.OnZoomListener listener)

设置ZoomButtonsController.OnZoomListener侦听接收回调进行缩放

参数

listener  介绍是否缩放的侦听器

 

public void setVisible (boolean visible)

设置缩放控件是否对用户可视

参数

visible  缩放控件是否对用户可视(true或者false 

 

public void setZoomInEnabled (boolean enabled)

是否允许空间放大

参数

enabled 是否允许空间放大(true或者false

 

public void setZoomOutEnabled (boolean enabled)

是否允许控件缩小

参数

enabled  是否允许控件缩小(true或者false

 

public void setZoomSpeed (long speed)

设置用户操作缩放按钮到缩放回调的延迟时间

参数

speed  以毫秒为单位的缩放回调的间隔时间

 

补充

         文章精选

                   Android Google map使用心得

                   googlemap加载多个overlay内存溢出

         示例代码


上一篇:下一篇: