move
<span id="span{{$index}}" ng-click="goTab({{$index}})" ng-class="{tabFont:selectIndex==$index?true:false}" style="padding:0 10px;" ng-repeat="tab in [1,2,3,4,5,6,7,8]" >{{tab}}
{{tab}}{{tab}} Ame.Cuisine{{tab}}{{tab}} </span>
$scope.selectIndex=index;
var element=document.getElementById("span"+index);
var start=element.offsetLeft;
var end=element.offsetWidth;
var selfWidth=document.getElementById("span"+index).clientWidth;
var contentWidth=document.documentElement.clientWidth;
if(start==0){
$ionicScrollDelegate.scrollTo(0, 0, true);
}else {
$ionicScrollDelegate.scrollTo(start-end, 0, true);
}/*else if(start>=contentWidth){
$ionicScrollDelegate.scrollTo(contentWidth, 0, true);
}else if(start>=(contentWidth/2)){
$ionicScrollDelegate.scrollTo(contentWidth/2, 0, true);
}*/
}
move的更多相关文章
- [LeetCode] Move Zeroes 移动零
Given an array nums, write a function to move all 0's to the end of it while maintaining the relativ ...
- 记录一则ORACLE MOVE操作后重建索引过程被强制中断导致的ORA-8104案例
环境:SunOS + Oracle 11.2.0.3 对部分表进行Move操作之后,未重建对应的索引,会导致ORA-1502 索引不可用. 此时需要用下面的查询拼接出重建不可用索引的sql语句: ...
- Error Domain=ASIHTTPRequestErrorDomain Code=8 "Failed to move file from"xxx/xxx"to"xxx/xxx"
今天真的好高兴呀 我解决了一个折磨了我一周的问题,真的是激动地要哭出来了,为了这个问题,我嘴也烂了,头发抓了一地啊.虽然解决方法,最后还是展现出了“百度”的伟大,但是我还是很开心,在这里我展示一下我的 ...
- LeetCode:Move Zeroes
LeetCode:Move Zeroes [问题再现] Given an array nums, write a function to move all 0's to the end of it w ...
- PHP中调用move_uploaded_file函数提示failed to open stream和 Unable to move
在做一个PHP文件上传系统的时候,使用move_uploaded_file进行文件上传,提示下面两个warning,不能成功上传文件 Warning: move_uploaded_file(uploa ...
- Leetcode Move Zeros
Given an array nums, write a function to move all 0's to the end of it while maintaining the relativ ...
- svn更改分支名字,move命令
名称 svn move — 移动一个文件或目录. 概要 svn move SRC DST 描述 这个命令移动文件或目录到你的工作拷贝或者是版本库. 提示 这个命令同svn copy加一个svn del ...
- LeetCode 283 Move Zeros
Problem: Given an array nums, write a function to move all 0's to the end of it while maintaining th ...
- C++11 feature: move constructor
There are heaps of good articles out there about C++ features including this move constructor. Howev ...
- [LintCode] Move Zeroes 移动零
Given an array nums, write a function to move all 0's to the end of it while maintaining the relativ ...
随机推荐
- Activtiy
Class Overview An activity is a single, focused thing that the user can do. Almost all activities in ...
- iOS开发之APP推送设置WIFI
在iOS开发过程中,有时需要连接网络.当访问请求,检测到网络不可用时,需要提示用户手动进行设置网络并告知用户操作路径设置可用的网络. 只需一行代码即可实现: - (void)viewDidLoad { ...
- supervisord
[简介] supervisord的官网:http://supervisord.org.看懂英文的可以不用看我的博客,直接看文档就行了,文档写得非常好.点个赞!! Supervisor是一个客户/服务器 ...
- ARM-linux嵌入式开发平台搭建1
初学嵌入式开发,由于是自学,走了很多弯路,现总结一下嵌入式ARM-LINUX开发环境搭建步骤: 1.安装linux系统,由于初学,我选择fedora 14.安装的具体步骤就不详细说了. 2.安装NFS ...
- python进阶
决定在python上有所突破 先看看知乎: 如何面试Python后端工程师? Python之美 - 知乎专栏 Python书籍推荐
- graph-tool文档(一)- 快速开始使用Graph-tool - 1.创建和操纵图
目录: 快速开始使用graph-tool 创建和操纵图 -- 遍历顶点和边 ----- 遍历所有顶点或边 ----- 遍历一个顶点的neighbourhood 名词解释: instante:实例 di ...
- Unity5.1 新的网络引擎UNET(二) UNET 官方推荐Demo案例
http://blog.csdn.net/u010019717/article/details/46873153 视频 http://www.iqiyi.com/playlist391685502.h ...
- IoC 之 2.3 IoC的配置使用(叁)
2.3.1 XML配置的结构 一般配置文件结构如下: <beans> <import resource="resource1.xml"/> <bea ...
- JAVA多线程和并发基础面试问答
转载: JAVA多线程和并发基础面试问答 多线程和并发问题是Java技术面试中面试官比较喜欢问的问题之一.在这里,从面试的角度列出了大部分重要的问题,但是你仍然应该牢固的掌握Java多线程基础知识来对 ...
- gulp-webpack工程化实现electron
参考网站: https://www.npmjs.com/package/babel-loader https://www.npmjs.com/package/gulp https://www.npmj ...