关于android-zoom-view.jar的Wiki

jme*_*ran 5 android scrollview zooming

有没有关于如何实现android-zoom-view.jar的Wiki或任何文档.我在http://code.google.com/p/android-zoom-view/上找到了它,我想尝试在我的应用程序上使用它来实现对android scrollview的缩放,但它让我很难做到这一点,因为我无法找到任何有关它的Wiki.

非常感谢任何意见或建议.

提前致谢

jme*_*ran 7

我想分享我的代码如何使用android-zoom-view.jar.这就是我使用它的方式.

  1. 为我想要应用缩放功能的视图创建一个新布局(R.layout.zoomable_view).
  2. 将它放在ZoomView中.
  3. 然后将ZoomView放置到要显示可缩放视图的主容器中.

    private ZoomView zoomView;
    
    @Override
    protected void onCreate(Bundle savedInstanceState) {
       super.onCreate(savedInstanceState);
       setContentView(R.layout.activity_zoomable);
    
       View v = ((LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE)).inflate(R.layout.zoomable_view, null, false);
       v.setLayoutParams(new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT));
    
       zoomView = new ZoomView(this);
       zoomView.addView(v);
    
       main_container = (LinearLayout) findViewById(R.id.main_container);
       main_container.addView(zoomView);            
    }
    
    Run Code Online (Sandbox Code Playgroud)

我希望这会有助于其他人.