slide

Android slide-in slide-out for activity

送分小仙女□ 提交于 2019-11-30 14:29:37
问题 I have an Android app in which nine of the activities do not load a layout file. Their views are private classes which extend the View class. The activity construct view objects at runtime and uses these objects instead of layout files. The problem that I have is that the views created these activities should slide in and slide out both left and right when switching to other views. I have used a ViewFlipper before but I am unable to one with my need here since view flippers take layout files

ViewDragHelper: how to use it?

怎甘沉沦 提交于 2019-11-30 12:02:57
问题 In the Google IO 2013, Google has announced a new version of the Support Library, which includes ViewDragHelper class. I saw the docs, but I couldn't find any sample of usage for this class. For example, a very typical situation: I have a custom view, which extends from FrameLayout and allows to drag some of the View s inside. For example, let it be a Button . I override onTouchEvent() and onInterceptTouchEvent() within my custom view, and if the button of the rect contains the touch

Xamarin Forms slide button

帅比萌擦擦* 提交于 2019-11-30 10:39:06
I'm looking to add a swipe function in my app that is pretty much identical to the unlock mechanic on (old?) iPhones (See pictures). I am struggling with how this could be achieved on a crossplatform solution. My immediate thought would be to use a slider and a custom renderer but unsure how to create the function of snapping to start if the user lets go before finishing the slide. Would appreciate if anyone could either assist with that function or if they have a better suggestion on how achieve this. Unless and until - you really need a particularly native look for every platform; you can

Trigger a button on page load

与世无争的帅哥 提交于 2019-11-30 09:44:11
I have this function $("a#<?php echo $custom_jq_settings['toggle']; ?>").click(function() { jQuery("#<?php echo $custom_jq_settings['div']; ?>").slideToggle(400); jQuery("#featurepagination").toggle(); jQuery("#featuretitlewrapper").toggle(); return false; }); And this is the button I want to trigger on page load <a href="#" id="featuretoggle" onclick="changeText('<?php if (is_front_page()) {?>Show<?php } else { ?>Show<?php } ?> Features');"><?php if (is_front_page()) {?>Hide<?php } else { ?>Hide<?php } ?> Features</a> I would like to trigger that button when the page loads so that it starts

PhoneGap/Cordova: JQuery animations running slow

只愿长相守 提交于 2019-11-30 09:04:45
I have built a an app in PhoneGap/Cordova and used the JQuery library for some simple animations like slideUp etc. They work fine on the simulator but when I try on an actual device the animations run really chunky and slow. Is there a way to speed this up? Or should I be using a different transitions frame work? If the latter is true can anyone suggest a good version for me to try? Thanks jQuery animations are done using a setInterval on the css properties being animated and it is not hardware accelerated on mobile devices. CSS Transitions are hardware accelerated on most modern devices and

盒子实例--滑动--轮播

妖精的绣舞 提交于 2019-11-30 05:22:55
<view class="root"> <!-- 标签栏的页签 固定高度 --> <view class="tabs"> <view class="item active"> <text>个性推荐</text> </view> <view class="item"> <text>歌单</text> </view> <view class="item"> <text>主播电台</text> </view> <view class="item"> <text>排行榜</text> </view> </view> <!-- 内容区域 自适应高度 --> <scroll-view class="content" scroll-y> <swiper class="slide" autoplay indicator-dots> <swiper-item> <image src="../../images/slide.png"></image> </swiper-item> <swiper-item> <image src="../../images/slide.png"></image> </swiper-item> <swiper-item> <image src="../../images/slide.png"></image> </swiper-item> </swiper> <view

Slide tab bar like in android market [closed]

只谈情不闲聊 提交于 2019-11-30 04:26:03
Does anyone know how to implement the bar like in android market (Categories, featured, top paid...) I've also seen it in the new version of SuperUser so i know it can be done. Thank you for your responses! Thanks to Selvin for the response. See as suggested: https://github.com/JakeWharton/Android-ViewPagerIndicator or this for a quick tutorial: http://android-developers.blogspot.com/2011/08/horizontal-view-swiping-with-viewpager.html Jake Wharton's Android-ViewPagerIndicator is a good option, but it doesn't support underline bar movement like below images(you can see what "underline bar

ViewDragHelper: how to use it?

眉间皱痕 提交于 2019-11-30 03:35:26
In the Google IO 2013, Google has announced a new version of the Support Library, which includes ViewDragHelper class. I saw the docs, but I couldn't find any sample of usage for this class. For example, a very typical situation: I have a custom view, which extends from FrameLayout and allows to drag some of the View s inside. For example, let it be a Button . I override onTouchEvent() and onInterceptTouchEvent() within my custom view, and if the button of the rect contains the touch coordinates and this is not a simple click, then I start to drag. So, what I must do with ViewDragHelper to get

jquery slide div within a div

放肆的年华 提交于 2019-11-29 22:29:24
问题 I have a container div element, this should contain all child div elements. I saw this thread: Slide a div offscreen using jQuery and I was wondering how to implement it (within a div element and not in the body). The code is working fine, but what if the "wrapper" div element has 500px width, how am I supposed to wrap the child divs? Am I need to use iframe or ...? For a better understanding I made this image: The red rectangle would be a window and the grey background the wall. You can only

How to create a slide panel

喜夏-厌秋 提交于 2019-11-29 16:39:33
I try to change a layout of the panel, but there are problems, because when I change layout the components remain on the panel and there are many bags. import java.awt.LayoutManager; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.JButton; import javax.swing.JFrame; import javax.swing.JPanel; public class LayoutTest extends JFrame { public LayoutTest() { initComponents(); } private void initComponents() { jPanel1 = new javax.swing.JPanel(); jButton = new JButton(); jPanel1.setBackground(new java.awt.Color(204, 204, 255)); jPanel1.setBorder(javax