{"action":"created","issue":{"url":"https://api.github.com/repos/BE-FE/iSlider/issues/216","labels_url":"https://api.github.com/repos/BE-FE/iSlider/issues/216/labels{/name}","comments_url":"https://api.github.com/repos/BE-FE/iSlider/issues/216/comments","events_url":"https://api.github.com/repos/BE-FE/iSlider/issues/216/events","html_url":"https://github.com/BE-FE/iSlider/issues/216","id":79056493,"number":216,"title":"Bug: New两个iSlider对象，onslidechange有BUG","user":{"login":"Bellzzy","id":12547577,"avatar_url":"https://avatars.githubusercontent.com/u/12547577?v=3","gravatar_id":"","url":"https://api.github.com/users/Bellzzy","html_url":"https://github.com/Bellzzy","followers_url":"https://api.github.com/users/Bellzzy/followers","following_url":"https://api.github.com/users/Bellzzy/following{/other_user}","gists_url":"https://api.github.com/users/Bellzzy/gists{/gist_id}","starred_url":"https://api.github.com/users/Bellzzy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Bellzzy/subscriptions","organizations_url":"https://api.github.com/users/Bellzzy/orgs","repos_url":"https://api.github.com/users/Bellzzy/repos","events_url":"https://api.github.com/users/Bellzzy/events{/privacy}","received_events_url":"https://api.github.com/users/Bellzzy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-21T15:56:10Z","updated_at":"2015-05-22T08:38:27Z","closed_at":null,"body":"任何一个对像移动时，都会影响onslidechange: \r\n\r\nislider1 = new iSlider({\r\n\t\t\t\t    data: domlist,\r\n\t\t\t\t    type:'dom',\r\n\t\t\t\t    dom: document.getElementById(\"iSlider-show\"),\r\n\t\t\t\t    duration: 3000,\r\n\t\t\t\t    animateType: 'default',\r\n\t\t\t\t    isAutoplay: true,\r\n\t\t\t\t    isLooping: true,\r\n\t\t\t\t    onslideend: function(idx){\r\n\t\t\t\t   \t\tidx = idx +1;\r\n\t\t\t\t   \t\tif(idx>=$(\"#iSlider-show li\").size()){\r\n\t\t\t\t   \t\t\tidx =0;\r\n\t\t\t\t   \t\t}\r\n\t\t\t\t   \t\t$(\".advtitle\").html($(\"#iSlider-show img:eq(\"+idx+\")\").attr(\"alt\"))\r\n\t\t\t\t   \t},\r\n\t\t\t\t   \tonslidechange: function(idx){\r\n\t\t\t\t   \t\tidx = idx +1;\r\n\t\t\t\t   \t\tif(idx>=$(\"#iSlider-show li\").size()){\r\n\t\t\t\t   \t\t\tidx =0;\r\n\t\t\t\t   \t\t}\r\n\t\t\t\t   \t\t$(\".advtitle\").html($(\"#iSlider-show img:eq(\"+idx+\")\").attr(\"alt\"))\r\n\t\t\t\t   \t}\r\n\t\t\t\t});\r\n\r\nislider2 = new iSlider({\r\n\t\t\t\t    data: domCate,\r\n\t\t\t\t    type:'dom',\r\n\t\t\t\t    dom: document.getElementById(\"iSlider-show-c\"),\r\n\t\t\t\t    duration: 3000,\r\n\t\t\t\t    animateType: 'default',\r\n\t\t\t\t    isAutoplay: false,\r\n\t\t\t\t    isLooping: true\r\n\t\t\t\t});\r\n\r\n如代码所示，操作islider2时，islider1的onslidechange也会有反映，也就是说onslidechange捕捉了两个对象的事件。"},"comment":{"url":"https://api.github.com/repos/BE-FE/iSlider/issues/comments/104571815","html_url":"https://github.com/BE-FE/iSlider/issues/216#issuecomment-104571815","issue_url":"https://api.github.com/repos/BE-FE/iSlider/issues/216","id":104571815,"user":{"login":"xieyu33333","id":2143576,"avatar_url":"https://avatars.githubusercontent.com/u/2143576?v=3","gravatar_id":"","url":"https://api.github.com/users/xieyu33333","html_url":"https://github.com/xieyu33333","followers_url":"https://api.github.com/users/xieyu33333/followers","following_url":"https://api.github.com/users/xieyu33333/following{/other_user}","gists_url":"https://api.github.com/users/xieyu33333/gists{/gist_id}","starred_url":"https://api.github.com/users/xieyu33333/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xieyu33333/subscriptions","organizations_url":"https://api.github.com/users/xieyu33333/orgs","repos_url":"https://api.github.com/users/xieyu33333/repos","events_url":"https://api.github.com/users/xieyu33333/events{/privacy}","received_events_url":"https://api.github.com/users/xieyu33333/received_events","type":"User","site_admin":false},"created_at":"2015-05-22T08:38:27Z","updated_at":"2015-05-22T08:38:27Z","body":"你可以在页面上把islider1和islider2这两个对象打印一下吗？"}}