Commit 539ba022 by Takatoshi Miura

#43070_scroll-keep_ios用スクロール位置調整

parent d1e0e0f0
...@@ -313,15 +313,6 @@ CHAT_DB.addFavoriteGroup = function(groupId) { ...@@ -313,15 +313,6 @@ CHAT_DB.addFavoriteGroup = function(groupId) {
} }
}; };
CHAT_DB.getContentList = function() {
if (CHAT_UTIL.isIOS()) {
//TODO ローカルDBからダウンロード済のコンテンツを取得
} else if (CHAT_UTIL.isAndroid()) {
return JSON.parse(android.getContentList());
}
};
CHAT_DB.getUserListByLoginId = function(loginIdList) { CHAT_DB.getUserListByLoginId = function(loginIdList) {
console.log(loginIdList); console.log(loginIdList);
if (CHAT_UTIL.isIOS()) { if (CHAT_UTIL.isIOS()) {
......
...@@ -383,7 +383,9 @@ $(function() { ...@@ -383,7 +383,9 @@ $(function() {
var afterWidth = window.innerWidth; var afterWidth = window.innerWidth;
var moreScroll = beforeHeight - afterHeight; var moreScroll = beforeHeight - afterHeight;
if (beforeHeight > afterHeight && (beforeHeight - afterHeight) > 50) { if (beforeHeight > afterHeight && (beforeHeight - afterHeight) > 50) {
if (beforeWidth == afterWidth) { if (CHAT_UTIL.isIOS()) {
window.scrollTo(0, beforeScroll + moreScroll);
} else if (beforeWidth == afterWidth) {
//キーボード表示時 //キーボード表示時
$('.room_container').css('margin-bottom', 0); $('.room_container').css('margin-bottom', 0);
window.scrollTo(0, beforeScroll + moreScroll - $('.footer_content_b').height()); window.scrollTo(0, beforeScroll + moreScroll - $('.footer_content_b').height());
...@@ -393,7 +395,9 @@ $(function() { ...@@ -393,7 +395,9 @@ $(function() {
} }
} else if (beforeHeight < afterHeight) { } else if (beforeHeight < afterHeight) {
$('.room_container').css('margin-bottom', footerHeight); $('.room_container').css('margin-bottom', footerHeight);
if (beforeWidth == afterWidth) { if (CHAT_UTIL.isIOS()) {
window.scrollTo(0, beforeScroll + moreScroll);
} else if (beforeWidth == afterWidth) {
//キーボード非表示 //キーボード非表示
window.scrollTo(0, beforeScroll + moreScroll + $('.footer_content_b').height()); window.scrollTo(0, beforeScroll + moreScroll + $('.footer_content_b').height());
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment