umano / AndroidSlidingUpPanel

This library provides a simple way to add a draggable sliding up panel (popularized by Google Music and Google Maps) to your Android application. Brought to you by Umano.

Home Page:http://umano.me

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I want to put it in the suspension window (WindowManager)

Zvirtuey opened this issue · comments

I want to put it in the suspension window (WindowManager), but restricted, sliding unfolds not good, do you have good advice?

can u provide more detailed information?

u want to put (slider panel?) into suspension window? but restricted(by who?), sliding unfolds not good(what do u mean?)

In service, I want to put this in WindowManager, but when you add a view, it won't expand if the height isn't set properly. I hope WindowManager's height is the same as SlidingUpPanelLayout change. Do you have any good suggestions!

    params = new WindowManager.LayoutParams(WindowManager.LayoutParams.TYPE_TOAST);
    params.format = PixelFormat.RGBA_8888;
    params.gravity = Gravity.TOP | Gravity.LEFT;
    params.flags = WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE |    WindowManager.LayoutParams.FLAG_NOT_TOUCH_MODAL
            | WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED | WindowManager.LayoutParams.FLAG_TURN_SCREEN_ON;
    mWindowManager = (WindowManager) getApplicationContext().getSystemService(Context.WINDOW_SERVICE);
    mWidth = mWindowManager.getDefaultDisplay().getWidth();
    mHeight = getScreenHeight(getApplicationContext());

    params.width =dip2px(480);
    params.height = dip2px(45);
    mWindowManager.addView(slidingView, params);

    mLayout.addPanelSlideListener(new SlidingUpPanelLayout.PanelSlideListener() {
        @Override
        public void onPanelSlide(View panel, float slideOffset) {
              //params.width =dip2px(400);
             // params.height = (int) (mHeight * slideOffset);
             // mWindowManager.updateViewLayout(slidingView, params);
        }

        @Override
        public void onPanelStateChanged(View panel, SlidingUpPanelLayout.PanelState previousState,        SlidingUpPanelLayout.PanelState newState) {
            Log.i(TAG, "onPanelStateChanged " + newState);
        }
    });

oh no...the sliding up panel is not really a view iirc. the it is more of a layout. why did u consider this sliding panel? u want the animation? cause this slider cannot solve ur problem

ok thanks , I'll think about the others.