Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
check
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abook_web
check
Commits
bcb0622d
Commit
bcb0622d
authored
Dec 11, 2012
by
Motohisa Nakano
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
20121211-2
parent
d7a9054c
Hide whitespace changes
Inline
Side-by-side
Showing
30 changed files
with
1491 additions
and
969 deletions
+1491
-969
abvw/bookmark.html
+4
-4
abvw/common/css/screenLock.css
+12
-1
abvw/common/js/common.js
+88
-204
abvw/common/js/jquery.treeview.js
+26
-17
abvw/common/js/screenLock.js
+2
-2
abvw/common/js/slideshow.js
+96
-39
abvw/common/json/lang/lang-en.json
+6
-4
abvw/common/json/lang/lang-ja.json
+4
-2
abvw/common/json/lang/lang-ko.json
+4
-2
abvw/contentview.html
+398
-164
abvw/css/contentview.css
+9
-2
abvw/css/setting.css
+2
-2
abvw/css/viewer.css
+42
-5
abvw/home.html
+2
-2
abvw/js/bookmark.js
+157
-274
abvw/js/contentsearch.js
+13
-5
abvw/js/contentview.js
+323
-119
abvw/js/contentview_Gomu.js
+29
-10
abvw/js/contentview_Maker.js
+21
-4
abvw/js/contentview_Marking.js
+9
-9
abvw/js/contentview_Memo.js
+3
-0
abvw/js/contentview_Paint.js
+11
-11
abvw/js/contentview_Pen.js
+30
-14
abvw/js/contentview_PopupText.js
+1
-1
abvw/js/header.js
+46
-28
abvw/js/history.js
+45
-12
abvw/js/home.js
+59
-24
abvw/js/login.js
+28
-5
abvw/js/settings.js
+20
-3
abvw/settings.html
+1
-0
No files found.
abvw/bookmark.html
View file @
bcb0622d
...
...
@@ -8,6 +8,9 @@
<meta
http-equiv=
"Cache-Control"
content=
"no-cache"
>
<meta
http-equiv=
"Expires"
content=
"-1"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"./common/css/jquery-ui.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"./common/css/jquery.toastmessage.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"./common/css/screen.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"css/common.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"css/list_shiori.css"
/>
...
...
@@ -17,10 +20,7 @@
<link
href=
"css/backup.css"
rel=
"stylesheet"
type=
"text/css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"./common/css/default.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
href=
"./common/css/screenLock.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"./common/css/jquery-ui.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"./common/css/jquery.toastmessage.css"
/>
<script
src=
"./common/js/jquery-1.8.1.min.js"
></script>
<script
src=
"./common/js/jquery-ui-1.8.23.custom.min.js"
></script>
...
...
abvw/common/css/screenLock.css
View file @
bcb0622d
...
...
@@ -17,5 +17,15 @@
margin
:
8px
auto
;
}
#passwd-txt
{
font-size
:
12pt
;
font-size
:
10pt
;
width
:
180px
;
}
.ime-inactive
{
ime-mode
:
inactive
;
}
.ime-disabled
{
ime-mode
:
disabled
;
}
\ No newline at end of file
abvw/common/js/common.js
View file @
bcb0622d
...
...
@@ -53,6 +53,26 @@ var Consts = {
ConstLockScreenTime
:
60000
}
/*
Define short keys for content view
*/
var
ShortKeys
=
{
// Move previous: arrow left <-
MovePrevious
:
37
,
// Move next: arrow right ->
MoveNext
:
39
,
// Zoom in: ","
ZoomIn
:
188
,
// Zoom out: "."
ZoomOut
:
190
,
// Fit: Enter
ZoomFit
:
13
,
// Show, hide toolbar: "["
ShowHideToolbar
:
219
,
// Show, hide marking: "]"
ShowHideMarking
:
221
};
// -------------------------------------------------
// Define all keys for local/session storage [start]
// -------------------------------------------------
...
...
@@ -207,10 +227,6 @@ var Keys = {
searchCond_genreId
:
'genreId'
,
// Session :検索条件(searchCond)_グループID:Interger
searchCond_groupId
:
'groupId'
,
// Local :ユーザ情報(userInfo)_セッションID:String
//userInfo_sid: 'userInfo_sid',
// Local :マーキングツールバー(marking)_ツールデフォルト:Interger(ベン:1, マーカー:2, 消しゴム:3)
marking_defaultDsp
:
'defaultDsp'
,
// Local :ペン書式設定(penOpt)_色:String
penOpt_color
:
'penOpt_color'
,
// Local :ペン書式設定(penOpt)_サイズ:Interger
...
...
@@ -223,14 +239,6 @@ var Keys = {
erase_color
:
'erase_color'
,
// Local :消しゴム書式設定(erase)_サイズ:Interger
erase_size
:
'erase_size'
,
// Local :インデックスデータ(index)_目次ID:Interger(Number)
index_ID
:
'index_ID'
,
// Local :インデックスデータ(index)_親の目次ID:Interger(Number)
index_parentID
:
'index_parentID'
,
// Local :インデックスデータ(index)_目次名:String(String)
index_title
:
'index_title'
,
// Local :インデックスデータ(index)_該当ページ:Interger(Number)
index_destPageNumber
:
'index_destPageNumber'
,
// Local :ユーザ情報(userInfo)_ログインID:String
userInfo_loginId
:
'loginId'
,
// Local :ユーザ情報(userInfo)_アカウントパス:String
...
...
@@ -241,31 +249,23 @@ var Keys = {
userInfo_lastLoginTime
:
'lastLoginTime'
,
// Local :ユーザ情報(userInfo)_パスワードスキップ日時:Datetime
userInfo_pwdSkipDt
:
'pwdSkipDt'
,
// Local:ユーザオプション(userOpt)_初期表示画面モード(本棚/リスト):Interger(0:本棚, 1:リスト)
userOpt_homeMode
:
'homeMode'
,
// Local :ユーザオプション(userOpt)_動画繰り返しフラグ:Interger(0: 繰り返しなし, 1: 繰り返しあり)
userOpt_videoMode
:
'videoMode'
,
// Local :ユーザオプション(userOpt)_音楽繰り返しフラグ:Interger(0: 繰り返しなし, 1: 繰り返しあり)
userOpt_musicMode
:
'musicMode'
,
// Local :ユーザオプション(userOpt)_マーキング表示設定:Interger(0:表示しない, 1:表示する)
userOpt_makingDsp
:
'makingDsp'
,
// Local :ユーザオプション(userOpt)_アラート表示設定:Interger(0:表示しない, 1:表示する)
userOpt_closeOrRefreshAlert
:
'userOpt_closeOrRefreshAlert'
,
// Local :ユーザオプション(userOpt)_バックアップ確認フラグ:Interger(0:する, 1:しない)
userOpt_bkConfirmFlg
:
'bkConfirmFlg'
,
// Local :閲覧履歴(viewlog)_コンテンツID:Interger
viewlog_contentId
:
'viewlog_contentId'
,
// Local :閲覧履歴(viewlog)_閲覧日:Datetime
viewlog_viewDt
:
'viewDt'
,
// Local :閲覧履歴(viewlog)_メタ更新バージョン:Interger
viewlog_metaVersion
:
'viewlog_metaVersion'
,
// Local :閲覧履歴(viewlog)_リソース更新バージョン:Interger
viewlog_resourceVersion
:
'viewlog_resourceVersion'
,
// Local :並び順(sortOpt)_表示モード:Interger(0:本棚, 1:リスト)
sortOpt_viewMode
:
'viewMode'
,
// Local :並び順(sortOpt)_表示区分:Interger(0:ジャンル, 1:グループ)
sortOpt_viewType
:
'viewType'
,
// Local :並び順(sortOpt)_ソート基準:Interger(1:コンテンツ検索, 2:タグ検索, 3:全文検索)
sortOpt_searchDivision
:
'sortOpt_searchDivision'
,
// Local:並び順(sortOpt)_ソート方法:Interger(1:タイトル名, 2:タイトル名(かな), 3:公開順)
// Local:
並び順(sortOpt)_ソート方法:Interger(1:タイトル名, 2:タイトル名(かな), 3:公開順)
sortOpt_sortType
:
'sortOpt_sortType'
,
// Local :しおりデータ(bookmark)_コンテンツID:Interger
bookmark_contentNo
:
'bookmark_contentNo'
,
...
...
@@ -274,20 +274,7 @@ var Keys = {
// Local :メモデータ(memo)_コンテンツID:Interger
memo_contentNo
:
'memo_contentNo'
,
// Local :メモデータ(memo)_ページNo:Interger
memo_pageNo
:
'memo_pageNo'
,
// Local :メモデータ(memo)_位置X座標:Interger
memo_posX
:
'posX'
,
// Local :メモデータ(memo)_位置Y座標:Interger
memo_posY
:
'posY'
,
// Local :メモデータ(memo)_内容(テキスト):String
memo_Text
:
'Text'
,
// Local :マーキングデータ(makingData)_コンテンツID:Interger
makingData_contentNo
:
'makingData_contentNo'
,
// Local :マーキングデータ(makingData)_ページNo:Interger
makingData_pageNo
:
'makingData_pageNo'
,
// Local :マーキングデータ(makingData)_内容(イメージオブジェクト):String
makingData_content
:
'content'
memo_pageNo
:
'memo_pageNo'
/* -------------------------------------------------------------------------------- */
};
...
...
@@ -722,16 +709,6 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
common_prePageNo
,
undefined
);
}
},
// Local :マーキングツールバー(marking)_ツールデフォルト:Interger(ベン:1, マーカー:2, 消しゴム:3)
marking_defaultDsp
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
marking_defaultDsp
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
marking_defaultDsp
,
undefined
);
}
},
// Local :ペン書式設定(penOpt)_色:String
penOpt_color
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -791,47 +768,6 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
erase_size
,
undefined
);
}
},
// Local :インデックスデータ(index)_目次ID:Interger(Number)
index_ID
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
index_ID
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
index_ID
,
undefined
);
}
},
// Local :インデックスデータ(index)_親の目次ID:Interger(Number)
index_parentID
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
index_parentID
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
index_parentID
,
undefined
);
}
},
// Local :インデックスデータ(index)_目次名:String(String)
index_title
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
index_title
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
index_title
,
undefined
);
}
},
// Local :インデックスデータ(index)_該当ページ:Interger(Number)
index_destPageNumber
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
index_destPageNumber
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
index_destPageNumber
,
undefined
);
}
},
// Local :ユーザ情報(userInfo)_最終ログイン日時:Datetime
userInfo_lastLoginTime
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -851,17 +787,6 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
userInfo_pwdSkipDt
,
undefined
);
}
},
// Local: ユーザオプション(userOpt)_初期表示画面モード(本棚/リスト):Interger(0:本棚, 1:リスト)
userOpt_homeMode
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
userOpt_homeMode
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
userOpt_homeMode
,
undefined
);
}
},
// Local :ユーザオプション(userOpt)_動画繰り返しフラグ:Interger(0: 繰り返しなし, 1: 繰り返しあり)
userOpt_videoMode
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -871,7 +796,6 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
userOpt_videoMode
,
undefined
);
}
},
// Local :ユーザオプション(userOpt)_音楽繰り返しフラグ:Interger(0: 繰り返しなし, 1: 繰り返しあり)
userOpt_musicMode
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -891,57 +815,24 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
userOpt_makingDsp
,
undefined
);
}
},
// Local :ユーザオプション(userOpt)_バックアップ確認フラグ:Interger(0:する, 1:しない)
userOpt_bkConfirmFlg
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
userOpt_bkConfirmFlg
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
userOpt_bkConfirmFlg
,
undefined
);
}
},
// Local :閲覧履歴(viewlog)_コンテンツID:Interger
viewlog_contentId
:
function
(
data
)
{
// Local :ユーザオプション(userOpt)_アラート表示設定:Interger(0:表示しない, 1:表示する)
userOpt_closeOrRefreshAlert
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
viewlog_contentId
,
undefined
);
operateData
(
arguments
,
Keys
.
userOpt_closeOrRefreshAlert
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
viewlog_contentId
,
undefined
);
return
operateData
(
arguments
,
Keys
.
userOpt_closeOrRefreshAlert
,
undefined
);
}
},
// Local :閲覧履歴(viewlog)_閲覧日:Datetime
viewlog_viewDt
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
viewlog_viewDt
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
viewlog_viewDt
,
undefined
);
}
},
// Local :閲覧履歴(viewlog)_メタ更新バージョン:Interger
viewlog_metaVersion
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
viewlog_metaVersion
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
viewlog_metaVersion
,
undefined
);
}
},
// Local :閲覧履歴(viewlog)_リソース更新バージョン:Interger
viewlog_resourceVersion
:
function
(
data
)
{
// Local :ユーザオプション(userOpt)_バックアップ確認フラグ:Interger(0:する, 1:しない)
userOpt_bkConfirmFlg
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
viewlog_resourceVersion
,
undefined
);
operateData
(
arguments
,
Keys
.
userOpt_bkConfirmFlg
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
viewlog_resourceVersion
,
undefined
);
return
operateData
(
arguments
,
Keys
.
userOpt_bkConfirmFlg
,
undefined
);
}
},
// Local :並び順(sortOpt)_表示モード:Interger(0:本棚, 1:リスト)
sortOpt_viewMode
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -1021,67 +912,6 @@ var ClientData = {
return
operateData
(
arguments
,
Keys
.
memo_pageNo
,
undefined
);
}
},
// Local :メモデータ(memo)_位置X座標:Interger
memo_posX
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
memo_posX
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
memo_posX
,
undefined
);
}
},
// Local :メモデータ(memo)_位置Y座標:Interger
memo_posY
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
memo_posY
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
memo_posY
,
undefined
);
}
},
// Local :メモデータ(memo)_内容(テキスト):String
memo_Text
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
memo_Text
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
memo_Text
,
undefined
);
}
},
// Local :マーキングデータ(makingData)_コンテンツID:Interger
makingData_contentNo
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
makingData_contentNo
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
makingData_contentNo
,
undefined
);
}
},
// Local :マーキングデータ(makingData)_ページNo:Interger
makingData_pageNo
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
makingData_pageNo
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
makingData_pageNo
,
undefined
);
}
},
// Local :マーキングデータ(makingData)_内容(イメージオブジェクト):String
makingData_content
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
operateData
(
arguments
,
Keys
.
makingData_content
,
undefined
);
}
else
{
return
operateData
(
arguments
,
Keys
.
makingData_content
,
undefined
);
}
},
// Session
IsRefresh
:
function
(
data
)
{
if
(
arguments
.
length
>
0
)
{
...
...
@@ -1898,10 +1728,10 @@ function getBase64Image(imgSource) {
function
LockScreen
()
{
if
(
avwUserSession
())
{
if
(
ClientData
.
serviceOpt_force_login_periodically
()
==
"Y"
)
{
var
message
=
i18nText
(
"sysInfoScrLock01"
);
//
var message = i18nText("sysInfoScrLock01");
screenLock
({
timeout
:
Consts
.
ConstLockScreenTime
,
html
:
'<img src="img/1222.png" alt="Screen Lock" /><br />'
+
message
,
html
:
'<img src="img/1222.png" alt="Screen Lock" /><br />'
,
//
+ message,
unlockFunc
:
unlockFunction
,
errorMessage
:
i18nText
(
'msgLoginErrWrong'
)
});
...
...
@@ -1937,6 +1767,11 @@ $(function () {
if
(
ClientData
.
userOpt_bkConfirmFlg
()
==
null
||
ClientData
.
userOpt_bkConfirmFlg
()
==
undefined
)
{
ClientData
.
userOpt_bkConfirmFlg
(
1
);
}
// タブ・ブラウザ終了・F5時のアラートが表示する
if
(
ClientData
.
userOpt_closeOrRefreshAlert
()
==
null
||
ClientData
.
userOpt_closeOrRefreshAlert
()
==
undefined
)
{
ClientData
.
userOpt_closeOrRefreshAlert
(
1
);
}
}
});
...
...
@@ -2273,4 +2108,52 @@ function isTouchDevice() {
}
return
false
;
}
/*
Get total bytes of jp chars
*/
function
getBytes
(
value
)
{
var
escapedStr
=
encodeURI
(
value
);
if
(
escapedStr
.
indexOf
(
"%"
)
!=
-
1
)
{
var
count
=
escapedStr
.
split
(
"%"
).
length
-
1
if
(
count
==
0
)
count
++
//perverse case; can't happen with real UTF-8
var
tmp
=
escapedStr
.
length
-
(
count
*
3
);
count
=
(
count
/
3
)
*
2
+
tmp
;
}
else
{
count
=
escapedStr
.
length
}
return
count
;
}
/*
Truncate by bytes
*/
function
truncateByBytes
(
value
,
byteCount
)
{
var
strResult
=
""
;
for
(
var
nIndex
=
0
;
nIndex
<
value
.
length
;
nIndex
++
)
{
if
(
getBytes
(
strResult
+
value
[
nIndex
])
<=
byteCount
)
{
strResult
+=
value
[
nIndex
];
}
else
{
break
;
}
}
return
strResult
;
}
function
ToogleLogoutNortice
()
{
var
isShow
=
false
;
if
(
ClientData
.
userOpt_closeOrRefreshAlert
()
==
1
)
{
// Checked
isShow
=
true
;
}
if
(
isShow
==
false
)
{
window
.
onbeforeunload
=
null
;
}
else
{
avwSetLogoutNortice
();
}
}
\ No newline at end of file
abvw/common/js/jquery.treeview.js
View file @
bcb0622d
...
...
@@ -292,7 +292,7 @@ function TreeNode() {
function
AddCategory
(
targetTreeView
,
sourceTreeNode
,
targetTreeNode
,
callbackFunction
)
{
var
branches
;
var
scriptCallback
=
""
;
if
(
callbackFunction
!=
undefined
&&
callbackFunction
!=
null
)
{
scriptCallback
+=
' onclick="'
;
...
...
@@ -306,21 +306,21 @@ function AddCategory(targetTreeView, sourceTreeNode, targetTreeNode, callbackFun
if
(
targetTreeNode
!=
undefined
&&
targetTreeNode
!=
null
)
{
if
(
sourceTreeNode
.
IsClosed
==
true
)
{
// Collapse
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
// Show total count
branches
=
$
(
"<li class='closed'><
span style='padding-left: 5px;' class='folder' "
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li class='closed'><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder' "
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
else
{
branches
=
$
(
"<li class='closed'><
span style='padding-left: 5px;' class='folder' "
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li class='closed'><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder' "
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
}
else
{
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
// Show total count
branches
=
$
(
"<li ><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li ><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
else
{
branches
=
$
(
"<li ><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li ><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
}
...
...
@@ -328,21 +328,21 @@ function AddCategory(targetTreeView, sourceTreeNode, targetTreeNode, callbackFun
else
{
if
(
sourceTreeNode
.
IsClosed
==
true
)
{
// Collapse
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
// Show total count
branches
=
$
(
"<li class='closed'><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li class='closed'><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
else
{
branches
=
$
(
"<li class='closed'><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li class='closed'><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
}
else
{
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
// Show total count
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNode
.
ContentCount
+
")<ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
else
{
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</span
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='folder'"
+
scriptCallback
+
">"
+
sourceTreeNode
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
><ul id='"
+
sourceTreeNode
.
Id
+
"'>"
+
"</ul></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
}
...
...
@@ -378,27 +378,27 @@ function AddItem(targetTreeView, sourceTreeNodeItem, targetTreeNode, callbackFun
if
(
targetTreeNode
!=
undefined
&&
targetTreeNode
!=
null
)
{
// Nodes of root
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
branches
=
$
(
"<li><
span class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
> ("
+
sourceTreeNodeItem
.
ContentCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNodeItem
.
ContentCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
else
{
branches
=
$
(
"<li><
span class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
> </li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> </li>"
).
appendTo
(
"#"
+
targetTreeNode
.
Id
);
}
}
else
{
if
(
sourceTreeNodeItem
.
Id
==
"all"
)
{
// All nodes
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='file lang root' lang='txtAll'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
> ("
+
targetTreeView
.
TotalCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='file lang root' lang='txtAll'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
targetTreeView
.
TotalCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
else
{
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='file lang root' lang='txtAll'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='file lang root' lang='txtAll'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
}
else
{
// Node of root but not be "all node"
if
(
targetTreeView
.
IsShowTotal
==
true
)
{
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
> ("
+
sourceTreeNodeItem
.
ContentCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
> ("
+
sourceTreeNodeItem
.
ContentCount
+
")</li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
else
{
branches
=
$
(
"<li><
span style='padding-left: 5px;' class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</span
></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
branches
=
$
(
"<li><
"
+
targetTreeView
.
CategoryTagName
+
" style='padding-left: 5px;' class='file'"
+
scriptCallback
+
">"
+
sourceTreeNodeItem
.
Text
+
"</"
+
targetTreeView
.
CategoryTagName
+
"
></li>"
).
appendTo
(
"#"
+
targetTreeView
.
Id
);
}
}
}
...
...
@@ -456,14 +456,21 @@ function AddChildNodeIndex(tree, parenTreeNode, childDataNode, callbackFunctionN
// Set unique id
childDataNode
.
Id
+=
nodeId
++
;
// Add category
AddCategory
(
tree
,
childDataNode
,
parenTreeNode
,
callbackFunctionName
);
if
(
childDataNode
.
ChildNodes
.
length
>
0
)
{
// Add category
AddCategory
(
tree
,
childDataNode
,
parenTreeNode
,
callbackFunctionName
);
for
(
var
nIndex
=
0
;
nIndex
<
childDataNode
.
ChildNodes
.
length
;
nIndex
++
)
{
// Call loop back
AddChildNodeIndex
(
tree
,
childDataNode
,
childDataNode
.
ChildNodes
[
nIndex
],
callbackFunctionName
);
}
}
else
{
// Add as item
childDataNode
.
IsCategory
=
false
;
AddItem
(
tree
,
childDataNode
,
parenTreeNode
,
callbackFunctionName
);
}
}
else
{
// Set unique id
...
...
@@ -502,6 +509,7 @@ function TreeView() {
this
.
TotalCount
=
0
;
this
.
IsShowTotal
=
true
;
this
.
ExpandNodes
=
[];
this
.
CategoryTagName
=
"span"
;
// Use to expand/ not expand when clicking in
this
.
Show
=
function
(
containerId
,
nodes
,
callbackFunctionName
)
{
var
tree
=
this
;
tree
.
Id
=
containerId
;
...
...
@@ -532,6 +540,7 @@ function TreeViewIndex() {
this
.
Nodes
=
new
Array
();
this
.
TotalCount
=
0
;
this
.
IsShowTotal
=
true
;
this
.
CategoryTagName
=
"span"
;
this
.
Show
=
function
(
containerId
,
nodes
,
callbackFunctionName
)
{
var
tree
=
this
;
tree
.
Id
=
containerId
;
...
...
abvw/common/js/screenLock.js
View file @
bcb0622d
...
...
@@ -143,9 +143,9 @@ function screenLock(options) {
var
tags
=
'<div id="'
+
elmId
+
'" class="screenLock">'
+
'<div style="display:table; width:100%; height:100%;">'
+
'<div style="display:table-cell; text-align:center; vertical-align:middle;">'
+
'<p class="screenLock-content">'
+
html
+
'</p>'
+
'<p class="screenLock-content">'
+
html
+
i18nText
(
'sysInfoScrLock01'
)
+
'</p>'
+
'<div id="pw" style="display:none;">'
+
'<input id="passwd-txt" placeholder="
input password
" type="password" value="" /> '
+
'<input id="passwd-txt" placeholder="
'
+
i18nText
(
'sysLockScrPwdInput'
)
+
'
" type="password" value="" /> '
+
'<button id="unlock-btn">OK</button>'
+
'<div id="screenLockErrMsg" class="screenLock-error" style="display:none;">'
+
errorMessage
+
'</div>'
+
'</div>'
+
...
...
abvw/common/js/slideshow.js
View file @
bcb0622d
...
...
@@ -31,41 +31,45 @@ function refreshSlideShowValue(){
//Show Image Preview
function
showImagePreview
(
targetId
,
imgList
){
refreshSlideShowValue
();
//Check if imageList is not null
if
(
imgList
!=
null
&&
imgList
!=
'undefined'
&&
imgList
.
length
>
0
){
slideshowImageCollection
=
setImageSource
(
imgList
);
//Check if targetId is not null
if
(
targetId
!=
null
&&
targetId
!=
'undefined'
){
if
(
slideshowImageCollection
.
length
==
1
){
targetId
.
html
(
''
);
targetId
.
append
(
'<div id="slideWrapper">'
+
'</div>'
);
var
mainImg
=
$
(
'#slideWrapper'
);
var
cssObj
=
{
'background-image'
:
'url('
+
slideshowImageCollection
[
0
].
thumbnail
+
')'
,
'background-repeat'
:
'no-repeat'
,
'background-size'
:
'contain'
,
'background-position'
:
'center'
,
'background-color'
:
'black'
};
mainImg
.
css
(
cssObj
);
}
else
{
renderSlideShowBackground
(
targetId
);
renderSelectImage
();
renderMainImage
(
0
);
handleImagePreviewEvent
();
}
}
}
else
{
renderSlideShowBackground
(
targetId
);
$
(
'.main-control'
).
css
(
'visibility'
,
'hidden'
);
$
(
'.slideshow-control'
).
css
(
'visibility'
,
'hidden'
);
}
function
showImagePreview
(
targetId
,
imgList
)
{
refreshSlideShowValue
();
//Check if imageList is not null
if
(
imgList
!=
null
&&
imgList
!=
'undefined'
&&
imgList
.
length
>
0
)
{
slideshowImageCollection
=
setImageSource
(
imgList
);
//Check if targetId is not null
if
(
targetId
!=
null
&&
targetId
!=
'undefined'
)
{
if
(
slideshowImageCollection
.
length
==
1
)
{
targetId
.
html
(
''
);
targetId
.
append
(
'<div id="slideWrapper">'
+
'</div>'
);
var
mainImg
=
$
(
'#slideWrapper'
);
var
cssObj
=
{
'background-image'
:
'url('
+
slideshowImageCollection
[
0
].
thumbnail
+
')'
,
'background-repeat'
:
'no-repeat'
,
'background-size'
:
'contain'
,
'background-position'
:
'center'
,
'background-color'
:
'black'
};
mainImg
.
css
(
cssObj
);
mainImg
.
parent
().
css
(
'padding-top'
,
'0px'
);
}
else
{
renderSlideShowBackground
(
targetId
);
renderSelectImage
();
renderMainImage
(
0
);
handleImagePreviewEvent
();
}
}
}
else
{
renderSlideShowBackground
(
targetId
);
$
(
'.main-control'
).
css
(
'visibility'
,
'hidden'
);
$
(
'.slideshow-control'
).
css
(
'visibility'
,
'hidden'
);
}
optimizeSizeImagePreview
();
}
//Set image source for slide show
...
...
@@ -98,9 +102,38 @@ function renderSlideShowBackground(targetId){
+
' </div>'
+
'</div>'
);
$
(
window
).
resize
(
function
()
{
optimizeSizeImagePreview
();
});
//handleImagePreviewEvent();
}
function
optimizeSizeImagePreview
()
{
var
maxW
=
"798"
;
var
ratio
=
1.566
;
var
maxH
=
maxW
/
ratio
;
if
(
$
(
"#dialog"
).
width
()
<
maxW
||
$
(
"#dialog"
).
height
()
<
maxH
)
{
if
(
$
(
"#dialog"
).
width
()
<
maxW
)
{
$
(
"#dialog"
).
css
(
'width'
,
maxW
+
'px'
);
$
(
"#dialog"
).
css
(
'height'
,
maxH
+
'px'
);
}
if
(
$
(
"#dialog"
).
height
()
<
maxH
)
{
$
(
"#dialog"
).
css
(
'height'
,
maxH
+
'px'
);
$
(
"#dialog"
).
css
(
'width'
,
maxW
+
'px'
);
}
}
else
{
$
(
"#dialog"
).
css
(
'width'
,
maxW
+
'px'
);
$
(
"#dialog"
).
css
(
'height'
,
maxH
+
'px'
);
}
$
(
"#dialog"
).
center
();
}
//render select image
function
renderSelectImage
(){
...
...
@@ -134,18 +167,42 @@ function handleImagePreviewEvent(){
$
(
'.thumbnail'
).
mouseleave
(
selectImgMouseLeaveFunction
);
$
(
'.main-control'
).
css
(
'opacity'
,
'0'
);
$
(
'#main-control-next'
).
mouseleave
(
mainControlNextMouseLeaveFunction
);
$
(
'#main-control-prev'
).
mouseleave
(
mainControlPrevMouseLeaveFunction
);
if
(
isTouchDevice
()
==
false
)
{
$
(
'.main-control'
).
mouseenter
(
mainControlMouseEnterFunction
);
//$('.main-control').mouseenter(mainControlMouseEnterFunction);
$
(
'#main-control-next'
).
mouseenter
(
mainControlNextMouseEnterFunction
);
$
(
'#main-control-prev'
).
mouseenter
(
mainControlPrevMouseEnterFunction
);
}
$
(
'.main-control'
).
mouseleave
(
mainControlMouseLeaveFunction
);
//
$('.main-control').mouseleave(mainControlMouseLeaveFunction);
$
(
'.thumbnail:first'
).
css
(
'box-shadow'
,
'0px 7px 7px #555'
);
handleDispNextPrevButton
();
}
function
mainControlNextMouseEnterFunction
(){
$
(
this
).
css
(
'opacity'
,
'0.5'
);
}
function
mainControlNextMouseLeaveFunction
(){
$
(
this
).
css
(
'opacity'
,
'0'
);
}
function
mainControlPrevMouseEnterFunction
(){
$
(
this
).
css
(
'opacity'
,
'0.5'
);
}
function
mainControlPrevMouseLeaveFunction
(){
$
(
this
).
css
(
'opacity'
,
'0'
);
}
//Image Preview next icon function
function
imageSelectNextFunction
(){
...
...
abvw/common/json/lang/lang-en.json
View file @
bcb0622d
...
...
@@ -48,8 +48,8 @@
"dspTitleNm"
:
"Title"
,
"dspTitleNmKn"
:
"Title(Kana)"
,
"txtPubDt"
:
"Released Date"
,
"txtRecordNum"
:
""
,
"txtRecordTotal"
:
""
,
"txtRecordNum"
:
"
"
,
"txtRecordTotal"
:
"
"
,
"dspViewMore"
:
">> Next {0} contents"
,
"txtGen"
:
"Genre"
,
"txtGr"
:
"Group"
,
...
...
@@ -64,7 +64,7 @@
"dspBkCancel"
:
"Logout"
,
"txtSearchResult"
:
"Result"
,
"dspHome"
:
"Home"
,
"txtLoginUser"
:
"(Ver.201212
07-1
)User:"
,
"txtLoginUser"
:
"(Ver.201212
11-2
)User:"
,
"txtAll"
:
"All"
,
"txtMkgSize"
:
"Size"
,
"txtMkgS"
:
"S"
,
...
...
@@ -112,5 +112,7 @@
"txtMemoEdit"
:
"Edit memo"
,
"txtMemoCopy"
:
"Copy"
,
"msgPageImgErr"
:
"Unable to show contents. Maybe it was deleted at server. Back home and choose another content."
,
"sysAppTitle"
:
"ABook Viewer for Web"
"sysAppTitle"
:
"ABook Viewer for Web"
,
"sysLockScrPwdInput"
:
"Input password"
,
"txtOpt005"
:
"Show alert when press F5.close tab.broswer."
}
abvw/common/json/lang/lang-ja.json
View file @
bcb0622d
...
...
@@ -64,7 +64,7 @@
"dspBkCancel"
:
"バックアップせずにログアウト"
,
"txtSearchResult"
:
"検索結果"
,
"dspHome"
:
"ホーム"
,
"txtLoginUser"
:
"(Ver.201212
07-1
)ログイン中:"
,
"txtLoginUser"
:
"(Ver.201212
11-2
)ログイン中:"
,
"txtAll"
:
"すべて"
,
"txtMkgSize"
:
"太さ"
,
"txtMkgS"
:
"小"
,
...
...
@@ -112,5 +112,7 @@
"txtMemoEdit"
:
"編集"
,
"txtMemoCopy"
:
"コピー"
,
"msgPageImgErr"
:
"コンテンツを表示することができません。コンテンツが削除された可能性があります。ホーム画面に戻り、異なるコンテンツを選択してください。"
,
"sysAppTitle"
:
"ABook閲覧ウェブ版"
"sysAppTitle"
:
"ABook閲覧ウェブ版"
,
"sysLockScrPwdInput"
:
"パスワードを入力してください"
,
"txtOpt005"
:
"タブ・ブラウザ終了・F5時のアラートが表示する"
}
abvw/common/json/lang/lang-ko.json
View file @
bcb0622d
...
...
@@ -64,7 +64,7 @@
"dspBkCancel"
:
"로그아웃"
,
"txtSearchResult"
:
"검색 결과"
,
"dspHome"
:
"홈"
,
"txtLoginUser"
:
"(Ver.201212
07-1
)로그인 중:"
,
"txtLoginUser"
:
"(Ver.201212
11-2
)로그인 중:"
,
"txtAll"
:
"전체"
,
"txtMkgSize"
:
"두께"
,
"txtMkgS"
:
"소"
,
...
...
@@ -112,5 +112,7 @@
"txtMemoEdit"
:
"편집"
,
"txtMemoCopy"
:
"복사"
,
"msgPageImgErr"
:
"컨텐츠를 표시할 수 없습니다. 이 컨텐츠는 삭제되었을 가능성이 있습니다."
,
"sysAppTitle"
:
"ABook : 멀티미디어 컨텐츠 플랫폼"
"sysAppTitle"
:
"ABook : 멀티미디어 컨텐츠 플랫폼"
,
"sysLockScrPwdInput"
:
"입력 암호"
,
"txtOpt005"
:
"탭 브라우저 종료 · F5 때 경고가 표시"
}
abvw/contentview.html
View file @
bcb0622d
...
...
@@ -27,9 +27,9 @@
<script
src=
"./common/js/jquery.treeview.js"
type=
"text/javascript"
></script>
<script
src=
"./common/js/jquery.treeview.edit.js"
type=
"text/javascript"
></script>
<script
src=
"./common/js/screenLock.js"
></script>
<script
src=
"./common/js/common.js"
></script>
<script
src=
"./common/js/avweb.js"
></script>
<script
src=
"./common/js/i18n.js"
></script>
<script
src=
"./common/js/common.js"
></script>
<script
src=
"./common/js/htmlparser.js"
></script>
<script
src=
"./common/js/textObject.js"
></script>
<script
src=
"./js/contentview.js"
></script>
...
...
@@ -886,14 +886,22 @@
//change class
$
(
'#imgmemo'
).
removeClass
();
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_device'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
}
/*handle image add memo */
ClientData
.
IsAddingMemo
(
false
);
//change class
$
(
'#imgaddmemo'
).
removeClass
();
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_device'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
}
}
else
{
ClientData
.
IsDisplayMemo
(
true
);
...
...
@@ -1211,23 +1219,42 @@
// }
// }
$
(
'#firstpage'
).
unbind
(
'click'
);
$
(
'#prevpage'
).
unbind
(
'click'
);
$
(
'#nextpage'
).
unbind
(
'click'
);
$
(
'#lastpage'
).
unbind
(
'click'
);
$
(
'#firstpage'
).
unbind
(
'click'
);
$
(
'#prevpage'
).
unbind
(
'click'
);
$
(
'#nextpage'
).
unbind
(
'click'
);
$
(
'#lastpage'
).
unbind
(
'click'
);
$
(
'#zoomfit'
).
unbind
(
'click'
);
$
(
'#zoomin'
).
unbind
(
'click'
);
$
(
'#zoomin'
).
removeClass
();
$
(
'#zoomin'
).
addClass
(
'expansion_off'
);
$
(
'#zoomout'
).
unbind
(
'click'
);
$
(
'#zoomout'
).
removeClass
();
$
(
'#zoomout'
).
addClass
(
'reduction_off'
);
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
true
);
$
(
'#zoomout'
).
addClass
(
'reduction_off'
);
if
(
avwUserEnvObj
.
os
!=
"android"
){
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
true
);
}
disable
(
'#txtSearch'
,
'#txtSlider'
);
$
(
'#button_next_canvas'
).
css
(
'display'
,
'none'
);
$
(
'#button_pre_canvas'
).
css
(
'display'
,
'none'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#firstpage'
).
removeClass
();
$
(
'#firstpage'
).
addClass
(
'begin'
);
$
(
'#prevpage'
).
removeClass
();
$
(
'#prevpage'
).
addClass
(
'prev'
);
$
(
'#nextpage'
).
removeClass
();
$
(
'#nextpage'
).
addClass
(
'next'
);
$
(
'#lastpage'
).
removeClass
();
$
(
'#lastpage'
).
addClass
(
'last'
);
$
(
'#zoomfit'
).
removeClass
();
$
(
'#zoomfit'
).
addClass
(
'fit'
);
}
}
/*enable all control on page */
...
...
@@ -1257,103 +1284,189 @@
$
(
"#slider_page"
).
css
(
'cursor'
,
'pointer'
);
$
(
".ui-slider-handle"
).
css
(
'cursor'
,
'pointer'
);
$
(
"#control_screen"
).
removeClass
();
$
(
"#control_screen_2"
).
removeClass
();
$
(
'#imgHome'
).
bind
(
'click'
,
imgHome_click
);
$
(
'#imgHome'
).
removeClass
();
$
(
'#imgHome'
).
addClass
(
'home'
);
$
(
'#imgBack'
).
bind
(
'click'
,
imgBack_click
);
$
(
'#imgBack'
).
removeClass
();
$
(
'#imgBack'
).
addClass
(
'back'
);
/*list bookmark */
$
(
'#listbookmark'
).
bind
(
'click'
,
showListBookMark
);
$
(
'#listbookmark'
).
removeClass
();
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
}
$
(
'#imgbookmark'
).
bind
(
'click'
,
bookmarkPage
);
$
(
'#imgbookmark'
).
removeClass
();
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
$
(
'#listindex'
).
bind
(
'click'
,
showListPageIndex
);
$
(
'#listindex'
).
removeClass
();
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index'
);
}
$
(
'#copytext'
).
bind
(
'click'
,
showCopyText
);
$
(
'#copytext'
).
removeClass
();
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy'
);
}
/* image memo */
$
(
'#imgmemo'
).
bind
(
'click'
,
handleMemo
);
$
(
'#imgmemo'
).
removeClass
();
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
}
/* image add memo */
$
(
'#imgaddmemo'
).
bind
(
'click'
,
handleAddMemo
);
$
(
'#imgaddmemo'
).
removeClass
();
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
}
$
(
'#imgaddmemo'
).
removeClass
();
$
(
'#imgmarking'
).
bind
(
'click'
,
imgmarking_click
);
$
(
'#imgmarking'
).
removeClass
();
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking'
);
}
$
(
'#imgmarking'
).
removeClass
();
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
$
(
'#imgmarkingtoolbar'
).
bind
(
'click'
,
handleDrawCanvas
);
$
(
'#imgmarkingtoolbar'
).
removeClass
();
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar'
);
}
$
(
'#imgmarkingtoolbar'
).
removeClass
();
}
$
(
'#firstpage'
).
bind
(
'click'
,
firstPage_click
);
/*$('#firstpage').bind('click',firstPage_click);
$('#firstpage').removeClass();
$('#prevpage').bind('click',prevPage_click);
$('#prevpage').removeClass();
$('#nextpage').bind('click',nextPage_click);
$('#nextpage').removeClass();
$('#lastpage').bind('click',lastPage_click);
$('#lastpage').removeClass();
$('#zoomfit').bind('click',screenFit);
$('#zoomfit').removeClass();*/
// $('#zoomin').bind('click',zoomIn);
// $('#zoomin').addClass('expansion');
// $("#zoomin").css('cursor', 'pointer');
// $('#zoomout').bind('click',zoomOut);
// $('#zoomout').addClass('reduction');
// $("#zoomout").css('cursor', 'pointer'); checkDisableButtonZoom();
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
false
);
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
false
);
enable
(
'#txtSearch'
,
'#txtSlider'
);
if
(
avwUserEnvObj
.
os
!=
"ipad"
&&
avwUserEnvObj
.
os
!=
"android"
){
$
(
'#button_next_canvas'
).
css
(
'display'
,
'block'
);
$
(
'#button_pre_canvas'
).
css
(
'display'
,
'block'
);
}
}
if
(
isTouchDevice
()
==
true
){
/* set css for device */
$
(
'#imgHome'
).
addClass
(
'home_device'
);
$
(
'#imgBack'
).
addClass
(
'back_device'
);
/*$('#firstpage').addClass('begin_device');
$('#prevpage').addClass('prev_device');
$('#nextpage').addClass('next_device');
$('#lastpage').addClass('last_device'); */
$
(
"#control_screen"
).
addClass
(
'toolbar_device'
);
$
(
"#control_screen_2"
).
addClass
(
'toolbar_device'
);
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_device'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList_device'
);
}
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy_device'
);
}
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index_device'
);
}
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_device'
);
}
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_device'
);
}
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking_device'
);
}
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_device'
);
}
}
}
else
{
/* set css for PC */
$
(
'#imgHome'
).
addClass
(
'home'
);
$
(
'#imgBack'
).
addClass
(
'back'
);
/*$('#firstpage').addClass('begin');
$('#prevpage').addClass('prev');
$('#nextpage').addClass('next');
$('#lastpage').addClass('last');*/
$
(
"#control_screen"
).
addClass
(
'toolbar'
);
$
(
"#control_screen_2"
).
addClass
(
'toolbar'
);
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
}
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy'
);
}
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index'
);
}
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
}
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
}
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking'
);
}
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar'
);
}
}
}
checkExistNextPrePage
();
}
...
...
@@ -1390,7 +1503,11 @@
//change class
$
(
'#imgbookmark'
).
removeClass
();
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_device'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
}
}
}
...
...
@@ -1595,14 +1712,30 @@
//change class
$
(
'#listbookmark'
).
removeClass
();
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_device'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
}
}
/* sort list bookmark */
function
sortBookmarkList
(){
var
bmList
=
[];
bmList
=
ClientData
.
BookMarkData
();
bmList
.
sort
(
function
(
a
,
b
){
var
a1
=
a
.
pageNo
,
b1
=
b
.
pageNo
;
if
(
a1
==
b1
)
return
0
;
return
a1
>
b1
?
1
:
-
1
;
});
ClientData
.
BookMarkData
(
bmList
);
}
/* get list info bookmark */
function
getBookmarklist
(
pos
){
var
isExistBookMarkInContent
=
false
;
sortBookmarkList
();
var
bmList
=
[];
bmList
=
ClientData
.
BookMarkData
();
...
...
@@ -1721,7 +1854,11 @@
//change class
$
(
'#listindex'
).
removeClass
();
$
(
'#listindex'
).
addClass
(
'index'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#listindex'
).
addClass
(
'index_device'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index'
);
}
/* unlock dialog overlay */
$
(
"#overlay"
).
hide
();
...
...
@@ -1766,7 +1903,13 @@
//add parent node
var
node
=
new
TreeNode
();
node
.
IsCategory
=
true
;
node
.
Text
=
htmlEncode
(
truncate
(
dataContent
[
i
].
title
,
20
));
//node.Text = htmlEncode(truncateByBytes(dataContent[i].title, 30));
/* check data text */
if
(
getBytes
(
dataContent
[
i
].
title
)
>
30
){
node
.
Text
=
htmlEncode
(
truncateByBytes
(
dataContent
[
i
].
title
,
30
))
+
'...'
;
}
else
{
node
.
Text
=
htmlEncode
(
dataContent
[
i
].
title
);
}
node
.
id
=
dataContent
[
i
].
ID
;
node
.
Value
=
dataContent
[
i
].
destPageNumber
;
AddChidrenNode
(
node
,
dataContent
)
...
...
@@ -1781,7 +1924,8 @@
$
(
"#divListIndex"
).
treeview
();
}
else
{
$
(
'#divListIndex'
).
children
().
remove
();
$
(
'#divListIndex'
).
append
(
'<span style="color:#333333; font-size:12px; cursor:default; text-decoration:none;">'
+
i18nText
(
'msgNoIndex'
)
+
'</span>'
);
$
(
'#divListIndex'
).
append
(
'<span style="color:#333333; font-size:12px; cursor:default; text-decoration:none;">'
+
i18nText
(
'msgNoIndex'
)
+
'</span>'
);
// //show dialog index
// $("#divListIndex").dialog({
// show: "blind",
...
...
@@ -1823,7 +1967,13 @@
//add child node
var
item
=
new
TreeNode
();
item
.
IsCategory
=
false
;
item
.
Text
=
htmlEncode
(
truncate
(
dataChild
[
i
].
title
,
20
));
//item.Text = htmlEncode(truncateByBytes(dataChild[i].title,30));
/* check data text */
if
(
getBytes
(
dataChild
[
i
].
title
)
>
30
){
item
.
Text
=
htmlEncode
(
truncateByBytes
(
dataChild
[
i
].
title
,
30
))
+
'...'
;
}
else
{
item
.
Text
=
htmlEncode
(
dataChild
[
i
].
title
);
}
item
.
id
=
dataChild
[
i
].
ID
;
item
.
Value
=
dataChild
[
i
].
destPageNumber
;
...
...
@@ -1875,7 +2025,11 @@
//change class
$
(
'#copytext'
).
removeClass
();
$
(
'#copytext'
).
addClass
(
'copy'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_device'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy'
);
}
/* unlock dialog overlay */
$
(
"#overlay"
).
hide
();
...
...
@@ -2226,7 +2380,7 @@
}
/* event next page */
function
nextPage_click
()
{
function
nextPage_click
()
{
if
(
getContent
().
hasNextPage
())
{
disableAllControl
();
...
...
@@ -2482,7 +2636,7 @@
context_draw.lineCap = 'square';
context_draw.strokeStyle = "#" + makerColor;
context_draw.stroke();
context_draw.globalCompositeOperation = '
source-ov
er';*/
context_draw.globalCompositeOperation = '
light
er';*/
context_draw
.
lineCap
=
"square"
;
context_draw
.
lineWidth
=
makerSize
;
...
...
@@ -2505,12 +2659,14 @@
this
.
mousemove
=
function
(
ev
)
{
if
(
isAddingMarking
==
true
){
if
(
tool
.
started
)
{
if
(
tool
.
started
&&
isPressLeftMouse
==
true
)
{
/*
if(isMoveOutDrawCanvas == true){
if
(
isMoveOutDrawCanvas
==
true
){
context_draw
.
moveTo
(
ev
.
_x
,
ev
.
_y
);
sx
=
ev
.
_x
;
sy
=
ev
.
_y
;
isMoveOutDrawCanvas
=
false
;
}
*/
}
if
(
markingType
==
'eraser'
)
{
//context.clearRect(ev._x, ev._y, ClientData.erase_size(), ClientData.erase_size());
...
...
@@ -2561,7 +2717,8 @@
];
if
(
sx
>
ev
.
_x
)
{
if
(
sy
>
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[1].x, ptStart[1].y);
context_draw.lineTo(ptStart[2].x, ptStart[2].y);
context_draw.lineTo(ptStart[3].x, ptStart[3].y);
...
...
@@ -2572,7 +2729,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
// 左上に描画する場合
...
...
@@ -2584,7 +2741,8 @@
context_draw
.
lineTo
(
ptEnd
[
1
].
x
,
ptEnd
[
1
].
y
);
context_draw
.
closePath
();
}
else
if
(
sy
<
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[0].x, ptStart[0].y);
context_draw.lineTo(ptStart[1].x, ptStart[1].y);
context_draw.lineTo(ptStart[2].x, ptStart[2].y);
...
...
@@ -2595,7 +2753,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2608,7 +2766,8 @@
context_draw
.
lineTo
(
ptEnd
[
0
].
x
,
ptEnd
[
0
].
y
);
context_draw
.
closePath
();
}
else
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[1].x, ptStart[1].y);
context_draw.lineTo(ptStart[2].x, ptStart[2].y);
context_draw.lineTo(ptEnd[3].x, ptEnd[3].y);
...
...
@@ -2617,7 +2776,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2630,7 +2789,8 @@
}
}
else
if
(
sx
<
ev
.
_x
)
{
if
(
sy
>
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[2].x, ptStart[2].y);
context_draw.lineTo(ptStart[3].x, ptStart[3].y);
context_draw.lineTo(ptStart[0].x, ptStart[0].y);
...
...
@@ -2641,7 +2801,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2654,7 +2814,8 @@
context_draw
.
lineTo
(
ptEnd
[
2
].
x
,
ptEnd
[
2
].
y
);
context_draw
.
closePath
();
}
else
if
(
sy
<
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[3].x, ptStart[3].y);
context_draw.lineTo(ptStart[0].x, ptStart[0].y);
context_draw.lineTo(ptStart[1].x, ptStart[1].y);
...
...
@@ -2665,7 +2826,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2678,7 +2839,8 @@
context_draw
.
lineTo
(
ptEnd
[
3
].
x
,
ptEnd
[
3
].
y
);
context_draw
.
closePath
();
}
else
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[3].x, ptStart[3].y);
context_draw.lineTo(ptStart[0].x, ptStart[0].y);
context_draw.lineTo(ptEnd[1].x, ptEnd[1].y);
...
...
@@ -2687,7 +2849,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2700,7 +2862,8 @@
}
}
else
{
if
(
sy
>
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[2].x, ptStart[2].y);
context_draw.lineTo(ptStart[3].x, ptStart[3].y);
context_draw.lineTo(ptEnd[0].x, ptEnd[0].y);
...
...
@@ -2709,7 +2872,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2720,7 +2883,8 @@
context_draw
.
lineTo
(
ptEnd
[
1
].
x
,
ptEnd
[
1
].
y
);
context_draw
.
closePath
();
}
else
if
(
sy
<
ev
.
_y
)
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[0].x, ptStart[0].y);
context_draw.lineTo(ptStart[1].x, ptStart[1].y);
context_draw.lineTo(ptEnd[2].x, ptEnd[2].y);
...
...
@@ -2729,7 +2893,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2740,7 +2904,8 @@
context_draw
.
lineTo
(
ptEnd
[
3
].
x
,
ptEnd
[
3
].
y
);
context_draw
.
closePath
();
}
else
{
/*context_draw.globalCompositeOperation = 'destination-out';
/*context_draw.beginPath();
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[0].x, ptStart[0].y);
context_draw.lineTo(ptStart[1].x, ptStart[1].y);
context_draw.lineTo(ptStart[2].x, ptStart[2].y);
...
...
@@ -2749,7 +2914,7 @@
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -2798,8 +2963,9 @@
if
(
tool
.
started
)
{
//tool.mousemove(ev);
tool
.
started
=
false
;
//
tool.started = false;
//context_draw.closePath();
isMoveOutDrawCanvas
=
true
;
}
/*if(isPressLeftMouse == true){
...
...
@@ -2888,12 +3054,17 @@
}
}
$
(
document
).
mouseup
(
function
(
e
){
if
(
e
.
which
==
1
)
isPressLeftMouse
=
false
});
/* handle display page from book mark page */
function
handleFromBookMarkPage
(){
function
handleFromBookMarkPage
(){
/* check exist pageno */
if
(
ClientData
.
bookmark_pageNo
()){
changePage
(
changePageNo
(
ClientData
.
bookmark_pageNo
()));
LocalStorageUtils
.
remove
(
Keys
.
bookmark_pageNo
);
//LocalStorageUtils.remove(Keys.bookmark_pageNo);
ClientData
.
bookmark_pageNo
(
null
)
}
}
...
...
@@ -2908,8 +3079,10 @@
/* check exist pageno */
if
(
ClientData
.
common_prePageNo
()){
changePage
(
changePageNo
(
ClientData
.
common_prePageNo
()));
LocalStorageUtils
.
remove
(
Keys
.
common_prePageNo
);
//changePage(changePageNo(ClientData.common_prePageNo()));
changePageWithoutSlide
(
changePageNo
(
ClientData
.
common_prePageNo
()));
//LocalStorageUtils.remove(Keys.common_prePageNo);
ClientData
.
common_prePageNo
(
null
)
}
}
...
...
@@ -2926,7 +3099,8 @@ function oldContent_Back(){
var
oldContent
=
oldDataBack
[
oldDataBack
.
length
-
1
];
/*move to page */
changePage
(
oldContent
.
oldPageIndex
);
//changePage(oldContent.oldPageIndex);
changePageWithoutSlide
(
oldContent
.
oldPageIndex
);
/*remove*/
oldDataBack
.
splice
(
oldDataBack
.
length
-
1
,
1
);
...
...
@@ -3063,52 +3237,52 @@ function oldContent_Back(){
}
/* handle keydown */
$
(
document
).
keydown
(
function
(
e
)
{
/* set fag true when click ctrl */
if
(
e
.
ctrlKey
)
{
ctrlMode
=
true
;
}
/* set hot key */
if
(
ctrlMode
==
true
)
{
if
(
ClientData
.
IsAddingMarking
()
==
true
||
isLoadingObject
==
true
)
{
/* do nothing*/
}
else
{
switch
(
e
.
keyCode
)
{
/* move page */
case
37
:
/* move prev */
if
(
getContent
().
hasPreviousPage
())
{
prevPage_click
();
}
break
;
case
39
:
/* move next */
if
(
getContent
().
hasNextPage
())
{
nextPage_click
();
}
break
;
/* zoom */
case
188
:
/* zoomIn */
zoomIn
();
break
;
case
190
:
/* zoomOut */
zoomOut
();
break
;
case
13
:
/* screenFit*/
screenFit
();
break
;
/* marking && toolbar */
case
219
:
/* handle toolbar */
handleDisplayToolbar
();
break
;
case
221
:
/* hide marking */
imgmarking_click
();
break
;
}
}
}
$
(
document
).
keydown
(
function
(
e
)
{
/* set fag true when click ctrl */
if
(
e
.
ctrlKey
)
{
ctrlMode
=
true
;
}
/* set hot key */
if
(
ctrlMode
==
true
)
{
if
(
ClientData
.
IsAddingMarking
()
==
true
||
isLoadingObject
==
true
)
{
/* do nothing*/
}
else
{
switch
(
e
.
keyCode
)
{
/* move page */
case
ShortKeys
.
MovePrevious
:
/* move prev */
if
(
getContent
().
hasPreviousPage
())
{
prevPage_click
();
}
break
;
case
ShortKeys
.
MoveNext
:
/* move next */
if
(
getContent
().
hasNextPage
())
{
nextPage_click
();
}
break
;
/* zoom */
case
ShortKeys
.
ZoomIn
:
/* zoomIn */
zoomIn
();
break
;
case
ShortKeys
.
ZoomOut
:
/* zoomOut */
zoomOut
();
break
;
case
ShortKeys
.
ZoomFit
:
/* screenFit*/
screenFit
();
break
;
/* marking && toolbar */
case
ShortKeys
.
ShowHideToolbar
:
/* handle toolbar */
handleDisplayToolbar
();
break
;
case
ShortKeys
.
ShowHideMarking
:
/* hide marking */
imgmarking_click
();
break
;
}
}
}
});
/* handle keydown */
...
...
@@ -3198,7 +3372,48 @@ function oldContent_Back(){
}
img
.
src
=
imgDrawingTemp
;
}
}
}
function
changePageWithoutSlide
(
pageMove
){
disableAllControl
();
$
(
'#divImageLoading'
).
css
(
'display'
,
'block'
);
avwGrabContentPageImage
(
ClientData
.
userInfo_accountPath
(),
{
contentId
:
contentID
,
sid
:
ClientData
.
userInfo_sid
(),
pageNo
:
pageMove
+
1
},
function
(
data
){
pageImages
=
data
;
/* get page Objects */
getPageObjectsByPageIndex
(
pageObjectsData
,
pageMove
);
getContent
().
setPageImages
(
totalPage
,
pageImages
).
setPageObjects
(
pageObjects
)
$
(
'#divImageLoading'
).
css
(
'display'
,
'none'
);
isFirstLoad
=
true
;
// screenFit();
getContent
().
toPage
(
pageMove
);
//changeSlider(pageMove);
/* handle slider bar */
handleSliderBar
();
if
(
dataPageTitle
[
pageMove
]){
if
(
dataPageTitle
[
pageMove
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
pageMove
]
+
' | '
+
i18nText
(
'sysAppTitle'
);
}
else
{
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
);
}
}
else
{
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
);
}
},
function
(
xmlHttpRequest
,
txtStatus
,
errorThrown
)
{
showErrorScreen
();
});
}
function
initPage
(){
...
...
@@ -3216,7 +3431,7 @@ function oldContent_Back(){
/* check login */
if
(
!
avwCheckLogin
(
ScreenIds
.
Login
))
return
;
// Set event to prevent leave
avwSet
LogoutNortice
();
Toogle
LogoutNortice
();
// Lock screen
LockScreen
();
...
...
@@ -3300,6 +3515,8 @@ function oldContent_Back(){
/* window resize event */
$
(
window
).
resize
(
function
()
{
sizingScreen
();
/* close dialog popuptext */
closeDialogPopUpText
();
});
...
...
@@ -3307,9 +3524,16 @@ function oldContent_Back(){
/*Init Page */
nAjaxLoad
++
;
if
(
nAjaxLoad
==
7
){
/* check move content */
if
(
ClientData
.
common_prePageNo
()){
/* handle from bookmark page */
//handleFromBookMarkPage();
/* check move content */
if
(
ClientData
.
bookmark_pageNo
()){
//changePage(changePageNo(ClientData.bookmark_pageNo()));
changePageWithoutSlide
(
changePageNo
(
ClientData
.
bookmark_pageNo
()));
ClientData
.
bookmark_pageNo
(
null
)
}
else
if
(
ClientData
.
common_prePageNo
()){
/* handle from jump content */
handleFromJumpContent
();
}
else
if
(
ClientData
.
IsJumpBack
()
==
true
){
...
...
@@ -3324,20 +3548,32 @@ function oldContent_Back(){
/* set pageTitle*/
if
(
dataPageTitle
[
0
]){
if
(
dataPageTitle
[
0
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
0
];
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
0
]
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
/* handle slider bar */
handleSliderBar
();
}
}
/* window resize event */
$
(
window
).
resize
(
function
()
{
resizeScreen
();
isChangeSizeScreen
=
false
;
isChangeSizeScreen
=
false
;
if
(
isTouchDevice
()
==
true
){
if
(
!
$
(
"#divDialogMemo"
).
is
(
":hidden"
))
{
$
(
"#divDialogMemo"
).
css
(
'left'
,
'30%'
);
$
(
"#divDialogMemo"
).
css
(
'top'
,
'30%'
);
}
}
/* close dialog popuptext */
closeDialogPopUpText
();
});
/* check status button */
...
...
@@ -3350,19 +3586,13 @@ function oldContent_Back(){
/* memo */
initImageMemo
();
initImageAddMemo
();
/* handle slider bar */
handleSliderBar
();
/* init image had draw */
initDisplayMarking
();
/* check status */
checkStatusImageMarking
();
/* handle from bookmark page */
handleFromBookMarkPage
();
trackTransforms
(
context_main
);
nAjaxLoad
=
0
;
...
...
@@ -3382,7 +3612,7 @@ function oldContent_Back(){
}
else
{
initPage
();
}
}
});
//LockScreen();
...
...
@@ -3398,6 +3628,10 @@ function oldContent_Back(){
<div
id=
"dialog"
class=
"web_dialog"
>
</div>
<div
id=
"divCheckExistMarking"
class=
"check_marking"
style=
"display:none"
>
<img
src=
"img/list/pic_2.png"
/>
</div>
<header
id =
"header_toolbar"
class=
"header"
>
<div
class =
"wrapper_header"
>
...
...
abvw/css/contentview.css
View file @
bcb0622d
...
...
@@ -182,7 +182,7 @@ div .ui-slider-range, .ui-widget-header, .ui-slider-range-max {
width
:
60%
;
height
:
80%
;
left
:
20%
;
top
:
2
%
;
top
:
10
%
;
background-color
:
black
;
/*border: 2px solid #336699;*/
padding
:
0px
;
...
...
@@ -430,7 +430,7 @@ div .ui-slider-range, .ui-widget-header, .ui-slider-range-max {
border-style
:
solid
;
width
:
0
;
height
:
0
;
border-width
:
20px
20px
20px
20
px
;
border-width
:
18px
18px
18px
18
px
;
}
/* HOVER STYLES */
.pop-up-memo
{
...
...
@@ -450,6 +450,13 @@ div .ui-slider-range, .ui-widget-header, .ui-slider-range-max {
text-decoration
:
underline
;
}
.check_marking
{
top
:
70px
;
left
:
20px
;
position
:
absolute
;
background-color
:
white
;
}
/*------------------Control Pen------------------------*/
.rayermenu1
{
...
...
abvw/css/setting.css
View file @
bcb0622d
...
...
@@ -65,7 +65,7 @@ body{
article
{
width
:
898px
;
height
:
6
55
px
;
height
:
6
80
px
;
border
:
1px
solid
#cccccc
;
padding
:
0
;
display
:
block
;
...
...
@@ -166,7 +166,7 @@ section div#user_info .passchgbtn a:hover:not(:target) {
div
#user_option
{
width
:
inherit
;
height
:
3
70
px
;
height
:
3
95
px
;
background
:
url(../img/common/back_dot.gif)
;
-moz-border-radius
:
6px
;
-webkit-border-radius
:
6px
;
...
...
abvw/css/viewer.css
View file @
bcb0622d
...
...
@@ -66,8 +66,8 @@ header{
/*overflow:hidden;*/
width
:
100%
;
position
:
absolute
;
top
:
0
;
left
:
0
;
top
:
0
px
;
left
:
0
px
;
}
.wrapper_header
{
...
...
@@ -134,6 +134,17 @@ header{
.hdLcolumn
a
.marking
{
background-position
:
-368px
0
;}
.hdLcolumn
a
.markingToolbar
{
background-position
:
-414px
0
;
margin
:
0
0
0
11px
;}
.hdLcolumn
a
.home_device
{
background-position
:
0
0
;}
.hdLcolumn
a
.back_device
{
background-position
:
-46px
0
;
margin
:
0
0
0
11px
;}
.hdLcolumn
a
.bmList_device
{
background-position
:
-92px
0
;}
.hdLcolumn
a
.bmAdd_device
{
background-position
:
-138px
0
;
margin
:
0
0
0
11px
;}
.hdLcolumn
a
.index_device
{
background-position
:
-184px
0
;}
.hdLcolumn
a
.copy_device
{
background-position
:
-230px
0
;}
.hdLcolumn
a
.memoDisplay_device
{
background-position
:
-276px
0
;}
.hdLcolumn
a
.memoAdd_device
{
background-position
:
-322px
0
;
margin
:
0
0
0
11px
;}
.hdLcolumn
a
.marking_device
{
background-position
:
-368px
0
;}
.hdLcolumn
a
.markingToolbar_device
{
background-position
:
-414px
0
;
margin
:
0
0
0
11px
;}
/*オンマウス時*/
.hdLcolumn
a
:hover
.home
{
background-position
:
0
-92px
;}
.hdLcolumn
a
:hover
.back
{
background-position
:
-46px
-92px
;}
...
...
@@ -213,7 +224,7 @@ header{
width
:
100%
;
height
:
60px
;
position
:
fixed
;
bottom
:
0
;
bottom
:
0
%
;
}
...
...
@@ -228,8 +239,8 @@ header{
width
:
100%
;
height
:
60px
;
position
:
absolute
;
bottom
:
0
;
left
:
0
;
bottom
:
0
%
;
left
:
0
%
;
}
.ftinner
{
...
...
@@ -1054,6 +1065,17 @@ aside.bookmarkBox .last{
.transition
.last
{
width
:
56px
;
background-position
:
-174px
0
;}
.transition
a
:hover
.last
{
background-position
:
-174px
-33px
;}
.transition
.begin_device
{
width
:
59px
;
background-position
:
0
-33px
;}
.transition
.prev_device
{
width
:
57px
;
background-position
:
-59px
-33px
;}
.transition
.next_device
{
width
:
58px
;
background-position
:
-116px
-33px
;}
.transition
.last_device
{
width
:
56px
;
background-position
:
-174px
-33px
;}
.transition
.begin_off
{
width
:
59px
;
background-position
:
0
0
;}
.transition
.prev_off
{
width
:
57px
;
background-position
:
-59px
0
;}
.transition
.next_off
{
width
:
58px
;
background-position
:
-116px
0
;}
.transition
.last_off
{
width
:
56px
;
background-position
:
-174px
0
;}
/*----------------------------*/
/* 13. sizing setting */
/*----------------------------*/
...
...
@@ -1087,8 +1109,12 @@ aside.bookmarkBox .last{
.sizing
.reduction
{
width
:
56px
;
background-position
:
-117px
0
;}
.sizing
a
:hover
.reduction
{
background-position
:
-117px
-33px
;}
.sizing
.expansion_device
{
width
:
59px
;
background-position
:
0
-33px
;}
.sizing
.fit_device
{
width
:
58px
;
background-position
:
-59px
-33px
;}
.sizing
.reduction_device
{
width
:
56px
;
background-position
:
-117px
-33px
;}
.sizing
.expansion_off
{
width
:
59px
;
background-position
:
0
0
;}
.sizing
.fit_off
{
width
:
58px
;
background-position
:
-59px
0
;}
.sizing
.reduction_off
{
width
:
56px
;
background-position
:
-117px
0
;}
/*----------------------------*/
/* 14. toolbar setting */
...
...
@@ -1106,6 +1132,17 @@ aside.bookmarkBox .last{
margin
:
0
0
0
10px
;
}
.toolbar_device
{
background
:
url(../img/viewer/toolbarbtn.png)
0
-60px
no-repeat
;
width
:
60px
;
height
:
0
;
padding-top
:
60px
;
display
:
block
;
overflow
:
hidden
;
font-size
:
0
;
margin
:
0
0
0
10px
;
}
.toolbar_off
{
background
:
url(../img/viewer/toolbarbtn.png)
0
-120px
no-repeat
;
width
:
60px
;
...
...
abvw/home.html
View file @
bcb0622d
...
...
@@ -141,9 +141,9 @@
<ul>
<li><span
class=
"lang"
lang=
"txtSort"
>
並べ替え
</span><span><b>
|
</b></span></li>
<li><a
class=
"
active_tops
lang"
id=
"control-sort-title"
lang=
"dspTitleNm"
>
タイトル名
</a><span
id=
"title-sorttype"
>
</span><span><b>
|
</b></span></li>
<li><a
class=
"lang"
id=
"control-sort-title"
lang=
"dspTitleNm"
>
タイトル名
</a><span
id=
"title-sorttype"
>
</span><span><b>
|
</b></span></li>
<li><a
id=
"control-sort-titlekana"
class=
"lang"
lang=
"dspTitleNmKn"
>
タイトル名(かな)
</a><span
id=
"titlekana-sorttype"
>
</span><span
id=
"separate"
><b>
|
</b></span></li>
<li><a
id=
"control-sort-releasedate"
class=
"lang"
lang=
"txtPubDt"
>
公開日
</a><span
id=
"rDate-sorttype"
>
</span></li>
<li><a
id=
"control-sort-releasedate"
class=
"
active_tops
lang"
lang=
"txtPubDt"
>
公開日
</a><span
id=
"rDate-sorttype"
>
</span></li>
</ul>
<p>
<label
id=
"dispPage"
class=
"pageNumControl"
style=
"visibility: hidden"
>
</label>
...
...
abvw/js/bookmark.js
View file @
bcb0622d
...
...
@@ -23,13 +23,16 @@
// Init function of page
$
(
document
).
ready
(
function
()
{
if
(
!
avwCheckLogin
(
ScreenIds
.
Login
))
return
;
LockScreen
();
// Synchronize bookmarks with server
SyncContent
();
if
(
!
avwCheckLogin
(
ScreenIds
.
Login
))
return
;
LockScreen
();
// Collection all detail of pages
bookmark_collectAllPages
();
document
.
title
=
i18nText
(
'dspShiori'
)
+
' | '
+
i18nText
(
'sysAppTitle'
);
// Set bookmark screen
...
...
@@ -218,60 +221,86 @@ function dspDelete_Click() {
if
(
$
(
"input[name='chkDelete']:checked"
).
length
>
0
)
{
lockLayout
();
$
(
"#delete_shiori"
).
show
();
$
(
"#delete_shiori"
).
center
();
//$('#dlgConfirm').dialog('open');
//$(".ui-dialog-titlebar").hide();
$
(
"#delete_shiori"
).
center
();
}
}
// Show detail content
function
ShowBookmark
()
{
var
hasMemo
=
false
;
var
hasMarking
=
false
;
var
contentid
=
""
;
var
pageNo
=
0
;
if
(
ClientData
.
BookMarkData
().
length
>
0
)
{
$
(
"#dspDelete"
).
show
();
$
(
"#dspDelete1"
).
show
();
if
(
avwHasError
())
{
return
;
}
//TotalThread = ClientData.BookMarkData().length;
for
(
var
nIndex
=
ClientData
.
BookMarkData
().
length
-
1
;
nIndex
>=
0
;
nIndex
--
)
{
hasMarking
=
false
;
hasMemo
=
false
;
else
{
var
hasMemo
=
false
;
var
hasMarking
=
false
;
var
contentid
=
""
;
var
pageNo
=
0
;
if
(
ClientData
.
BookMarkData
().
length
>
0
)
{
$
(
"#dspDelete"
).
show
();
$
(
"#dspDelete1"
).
show
();
}
//TotalThread = ClientData.BookMarkData().length;
for
(
var
nIndex
=
ClientData
.
BookMarkData
().
length
-
1
;
nIndex
>=
0
;
nIndex
--
)
{
hasMarking
=
false
;
hasMemo
=
false
;
contentid
=
ClientData
.
BookMarkData
()[
nIndex
].
contentid
;
pageNo
=
ClientData
.
BookMarkData
()[
nIndex
].
pageNo
;
contentid
=
ClientData
.
BookMarkData
()[
nIndex
].
contentid
;
pageNo
=
ClientData
.
BookMarkData
()[
nIndex
].
pageNo
;
// Check if contentid has marking
for
(
var
nIndex1
=
0
;
nIndex1
<
ClientData
.
MarkingData
().
length
;
nIndex1
++
)
{
// Check if contentid has marking
for
(
var
nIndex1
=
0
;
nIndex1
<
ClientData
.
MarkingData
().
length
;
nIndex1
++
)
{
if
(
ClientData
.
MarkingData
()[
nIndex1
].
contentid
==
contentid
if
(
ClientData
.
MarkingData
()[
nIndex1
].
contentid
==
contentid
&&
ClientData
.
MarkingData
()[
nIndex1
].
pageNo
==
pageNo
)
{
hasMarking
=
true
;
hasMarking
=
true
;
}
}
}
// Check if contentid has memo
for
(
var
nIndex1
=
0
;
nIndex1
<
ClientData
.
MemoData
().
length
;
nIndex1
++
)
{
// Check if contentid has memo
for
(
var
nIndex1
=
0
;
nIndex1
<
ClientData
.
MemoData
().
length
;
nIndex1
++
)
{
if
(
ClientData
.
MemoData
()[
nIndex1
].
contentid
==
contentid
if
(
ClientData
.
MemoData
()[
nIndex1
].
contentid
==
contentid
&&
ClientData
.
MemoData
()[
nIndex1
].
pageNo
==
pageNo
)
{
hasMemo
=
true
;
hasMemo
=
true
;
}
}
var
pageDetail
;
var
contentTitle
=
""
;
var
contentTitleKana
=
""
;
// Search current page if collection that get details before
for
(
var
nIndex2
=
0
;
nIndex2
<
collection_contents
.
length
;
nIndex2
++
)
{
if
(
collection_contents
[
nIndex2
].
contentid
==
contentid
)
{
contentTitle
=
collection_contents
[
nIndex2
].
contentTitle
;
contentTitleKana
=
collection_contents
[
nIndex2
].
contentTitleKana
;
// Search in pages
for
(
var
nIndex3
=
0
;
nIndex3
<
collection_contents
[
nIndex2
].
pages
.
length
;
nIndex3
++
)
{
if
(
pageNo
==
collection_contents
[
nIndex2
].
pages
[
nIndex3
].
pageNo
)
{
pageDetail
=
collection_contents
[
nIndex2
].
pages
[
nIndex3
];
break
;
}
}
}
}
}
// if (IsErrorPage(contentid, pageNo)) {
// insertRowError(contentid, htmlEncode(ClientData.BookMarkData()[nIndex].contentTitle), pageNo);
// }
// else {
// callApi.execute(contentid, ClientData.userInfo_sid(), pageNo, hasMemo, hasMarking, htmlEncode(ClientData.BookMarkData()[nIndex].contentTitle), nIndex);
// }
callApi
.
execute
(
contentid
,
ClientData
.
userInfo_sid
(),
pageNo
,
hasMemo
,
hasMarking
,
htmlEncode
(
ClientData
.
BookMarkData
()[
nIndex
].
contentTitle
),
nIndex
);
if
(
pageDetail
)
{
// If bookmark does not exist
if
(
pageDetail
.
existed
==
true
)
{
// Show normal
UpdateBookmark
(
contentid
,
pageDetail
.
pageNo
,
contentTitle
,
contentTitleKana
);
insertRow
(
contentid
,
"data:image/jpeg;base64,"
+
pageDetail
.
pageThumbnail
,
htmlEncode
(
contentTitle
),
pageDetail
.
pageText
,
pageDetail
.
pageNo
,
hasMemo
,
hasMarking
,
nIndex
);
}
else
{
// Not existed -> Show error
insertRowError
(
contentid
,
htmlEncode
(
contentTitle
),
pageDetail
.
pageNo
);
}
}
}
$
(
"a[name='dspRead']"
).
unbind
(
'click'
);
$
(
"a[name='dspRead']"
).
click
(
dspRead_Click
);
}
$
(
"a[name='dspRead']"
).
unbind
(
'click'
);
$
(
"a[name='dspRead']"
).
click
(
dspRead_Click
);
}
// Hide all sorting symbol
function
HideSorting
()
{
...
...
@@ -481,52 +510,6 @@ function UpdateBookmark(contentid, pageNo, contentTitle, contentTitleKana) {
ClientData
.
BookMarkData
(
arrBookmarks
);
}
// Call API controller
var
callApi
=
{
contentid
:
""
,
pageNo
:
0
,
execute
:
function
(
contentid
,
sid
,
pageNo
,
hasMemo
,
hasMarking
,
contentTitle
,
index
)
{
this
.
contentid
=
contentid
;
this
.
pageNo
=
pageNo
;
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webContentPage"
,
"GET"
,
{
contentId
:
contentid
,
sid
:
sid
,
pageNos
:
pageNo
,
thumbnailFlg
:
1
},
function
(
data
)
{
if
(
data
.
pages
.
length
==
0
)
{
// Page does not exist
AddErrorPage
(
contentid
,
pageNo
);
insertRowError
(
contentid
,
htmlEncode
(
contentTitle
),
pageNo
);
}
else
{
// Update local title to be equal to server
UpdateBookmark
(
contentid
,
pageNo
,
data
.
contentTitle
,
data
.
contentTitleKana
);
contentTitle
=
data
.
contentTitle
;
// Insert to grid
insertRow
(
contentid
,
"data:image/jpeg;base64,"
+
data
.
pages
[
0
].
pageThumbnail
,
htmlEncode
(
contentTitle
),
data
.
pages
[
0
].
pageText
,
pageNo
,
hasMemo
,
hasMarking
,
index
);
}
/*
// Update local title to be equal to server
UpdateBookmark(contentid, pageNo, data.contentTitle, data.contentTitleKana);
contentTitle = data.contentTitle;
for (var nIndex2 = 0; nIndex2 < data.pages.length; nIndex2++) {
if (pageNo == data.pages[nIndex2].pageNo) {
// Update bookmark
// Insert to grid
insertRow(contentid, "data:image/jpeg;base64," + data.pages[nIndex2].pageThumbnail, htmlEncode(contentTitle), data.pages[nIndex2].pageText, pageNo, hasMemo, hasMarking, index);
//TotalThread--;
break;
}
}
$("a[name='dspRead']").unbind('click');
$("a[name='dspRead']").click(dspRead_Click);
*/
},
null
);
}
}
/*
Insert error row
...
...
@@ -534,26 +517,7 @@ var callApi = {
function
insertRowError
(
contentid
,
pageTitle
,
pageNo
)
{
var
newRow
=
""
;
// newRow += "<tr>";
// newRow += "<td id='check'>";
// newRow += "<input type='checkbox' name='chkDelete' value='{\"contentid\":" + contentid + ", \"pageNo\":" + pageNo + "}'/>";
// newRow += "</td>";
// newRow += "<td colspan='2'>";
// newRow += '<div><label id="Label1">' + pageTitle + '</label></div>';
// newRow += "<label class='lang bookmarl_deleted' lang='msgShioriDeleted'>" + i18nText('msgShioriDeleted') + "</label>";
// newRow += "</td>";
// newRow += "<td>";
// newRow += "</td>";
// newRow += "<td>";
//
// newRow += "</td>";
// newRow += "<td>";
// newRow += "</td>";
// newRow += "</tr>";
// $('#grid').append(newRow);
newRow
+=
"<section>"
;
newRow
+=
" <div class='cnt_section'>"
;
newRow
+=
" <div class='check'>"
;
...
...
@@ -649,53 +613,10 @@ function insertRow(contentid, pageThumbnail, pageTitle, pageText, pageNo, hasMem
newRow
+=
"</ul>"
;
newRow
+=
"</div>"
;
newRow
+=
"</div>"
;
//newRow += "<button class='button lang' name='dspRead' value='{\"contentid\":" + contentid + ", \"pageNo\":" + pageNo + "}' lang='dspRead'>読む</button>";
newRow
+=
"</div>"
;
newRow
+=
"</section>"
;
//var chks = $("input[name='chkDelete']");
$
(
'#pnlTop'
).
after
(
newRow
);
/*
if (chks.length == 0) {
// Add first row
$('#grid').append(newRow);
}
else {
// From second row
for (var nIndex = 0; nIndex < chks.length; nIndex++) {
var row = $(chks[nIndex]).parent().parent();
var data = JSON.parse(chks[nIndex].value);
if (index <= data.index) {
row.before(newRow);
break;
}
else {
// Add to last position
if (nIndex >= chks.length - 1) {
row.after(newRow);
break;
}
else { // Between
var data1 = JSON.parse(chks[nIndex + 1].value);
if (index > data.index && index <= data1.index) {
row.after(newRow);
break;
}
else {
// Nothing
}
}
}
}
}
//$('#grid tr:last').after(newRow);
//$('#grid').append(newRow);
//$('#grid tr:last').eq(index).after(newRow);
*/
}
...
...
@@ -713,17 +634,7 @@ Setting dialog [start]
----------------------------------------------------------------------------
*/
$
(
function
()
{
// $('#dlgConfirm').dialog({
// autoOpen: false,
// modal: true,
// resizable: false,
// width: 550,
// height: 200,
// minWidth: 550,
// minHeight: 200
// });
$
(
"#dspTitleNm"
).
click
(
dspTitleNm_Click
);
$
(
"#dspTitleNmKn"
).
click
(
dspTitleNmKn_Click
);
$
(
"#dspPubDt"
).
click
(
dspPubDt_Click
);
...
...
@@ -737,23 +648,79 @@ $(function () {
$
(
"#dspTitleNmKn"
).
show
();
$
(
"#dspTitleNmKn_Seperate"
).
show
();
}
// LockScreen();
});
// Contains non-exist pages
var
bookmark_errorPages
;
// Contains non-exist content
var
bookmark_errorContent
;
var
bookmark_errorContent
=
[]
;
// Contain contents
var
collection_contents
;
var
collection_contents
=
[]
;
// Contain pages
var
collection_pages
;
/*
Get all detail pages of content in bookmark
*/
function
bookmark_collectAllPages
()
{
var
arrBookMarks
=
ClientData
.
BookMarkData
();
for
(
var
nIndex
=
0
;
nIndex
<
collection_contents
.
length
;
nIndex
++
)
{
var
contentid
=
collection_contents
[
nIndex
].
contentid
;
var
pages
=
[];
// Collect all pages of current content
for
(
var
nIndex1
=
0
;
nIndex1
<
arrBookMarks
.
length
;
nIndex1
++
)
{
// Found content
if
(
arrBookMarks
[
nIndex1
].
contentid
==
contentid
)
{
pages
.
push
({
pageNo
:
arrBookMarks
[
nIndex1
].
pageNo
,
pageText
:
""
,
pageThumbnail
:
""
,
existed
:
false
});
}
}
// Add collected pages to content
collection_contents
[
nIndex
].
pages
=
pages
;
// Join pages to request to server
var
strPageNos
=
buildPageNos
(
collection_contents
[
nIndex
].
pages
);
// Call api to get all details of pages 1 time
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webContentPage"
,
"GET"
,
{
contentId
:
contentid
,
sid
:
ClientData
.
userInfo_sid
(),
pageNos
:
strPageNos
,
thumbnailFlg
:
1
},
function
(
data
)
{
collection_contents
[
nIndex
].
contentTitle
=
data
.
contentTitle
;
collection_contents
[
nIndex
].
contentTitleKana
=
data
.
contentTitleKana
;
for
(
var
nIndex2
=
0
;
nIndex2
<
collection_contents
[
nIndex
].
pages
.
length
;
nIndex2
++
)
{
var
comparePageNo
=
collection_contents
[
nIndex
].
pages
[
nIndex2
].
pageNo
;
for
(
var
nIndex3
=
0
;
nIndex3
<
data
.
pages
.
length
;
nIndex3
++
)
{
if
(
comparePageNo
==
data
.
pages
[
nIndex2
].
pageNo
)
{
// Set flag to determine page existed
collection_contents
[
nIndex
].
pages
[
nIndex2
].
existed
=
true
;
// Store detail of page
collection_contents
[
nIndex
].
pages
[
nIndex2
].
pageText
=
data
.
pages
[
nIndex2
].
pageText
;
collection_contents
[
nIndex
].
pages
[
nIndex2
].
pageThumbnail
=
data
.
pages
[
nIndex2
].
pageThumbnail
;
}
}
}
},
null
);
}
}
/*
Build pageNos
*/
function
buildPageNos
(
pages
)
{
var
strResult
=
""
;
for
(
var
nIndex
=
0
;
nIndex
<
pages
.
length
;
nIndex
++
)
{
if
(
strResult
==
""
)
{
strResult
=
""
+
pages
[
nIndex
].
pageNo
;
}
else
{
strResult
+=
","
+
pages
[
nIndex
].
pageNo
;
}
}
return
strResult
;
}
/*
Check a content is error or not
...
...
@@ -785,33 +752,7 @@ function IsOKCheckedContent(strContentId) {
return
isOK
;
}
/*
Check a page is error or not (error pages were checked before)
*/
function
IsErrorPage
(
strContentId
,
strPageNo
)
{
var
isError
=
false
;
for
(
var
nIndex
=
0
;
nIndex
<
bookmark_errorPages
.
length
;
nIndex
++
)
{
if
(
strContentId
==
bookmark_errorPages
[
nIndex
].
contentid
&&
strPageNo
==
bookmark_errorPages
[
nIndex
].
pageNo
)
{
isError
=
true
;
break
;
}
}
return
isError
;
}
function
AddErrorPage
(
strContentId
,
strPageNo
)
{
var
isFound
=
false
;
for
(
var
nIndex
=
0
;
nIndex
<
collection_pages
.
length
;
nIndex
++
)
{
if
(
collection_pages
[
nIndex
].
contentid
==
strContentId
&&
collection_pages
[
nIndex
].
pageNo
==
strPageNo
)
{
isFound
=
true
;
}
}
if
(
!
isFound
)
{
var
onePair
=
{
contentid
:
strContentId
,
pageNo
:
strPageNo
};
bookmark_errorPages
.
push
(
onePair
);
}
}
// Add OK checked content
function
AddContent
(
strContentId
)
{
var
isFound
=
false
;
for
(
var
nIndex
=
0
;
nIndex
<
collection_contents
.
length
;
nIndex
++
)
{
...
...
@@ -822,71 +763,7 @@ function AddContent(strContentId) {
}
// Add to bufer if it does not exist
if
(
!
isFound
)
{
collection_contents
.
push
({
contentid
:
strContentId
});
}
}
function
SyncPages
()
{
for
(
var
nIndex
=
0
;
nIndex
<
collection_contents
.
length
;
nIndex
++
)
{
// Get one content
var
oneContent
=
collection_contents
[
nIndex
];
var
params
=
{
sid
:
ClientData
.
userInfo_sid
(),
contentId
:
oneContent
.
contentid
,
thumbnailFlg
:
0
}
var
webContentPage
;
// Get all pages of content
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webContentPage"
,
'GET'
,
params
,
function
(
data
)
{
// Success
if
(
data
.
pages
)
{
webContentPage
=
data
.
pages
;
}
},
null
);
if
(
webContentPage
)
{
if
(
webContentPage
.
length
>
0
)
{
var
arrBookmarks
=
ClientData
.
BookMarkData
();
for
(
var
nIndex1
=
0
;
nIndex1
<
arrBookmarks
.
length
;
nIndex1
++
)
{
// Get one bookmar entity
var
oneBookMark
=
arrBookmarks
[
nIndex1
];
// Found contentid
if
(
oneBookMark
.
contentid
==
oneContent
.
contentid
)
{
var
isFoundPage
=
false
;
for
(
var
nIndex2
=
0
;
nIndex2
<
webContentPage
.
length
;
nIndex2
++
)
{
if
(
oneBookMark
.
pageNo
==
webContentPage
[
nIndex2
].
pageNo
)
{
// Found pageNo
isFoundPage
=
true
;
break
;
}
}
if
(
!
isFoundPage
)
{
AddErrorPage
(
oneBookMark
.
contentid
,
oneBookMark
.
pageNo
);
}
}
}
}
else
{
// webContentPage.length = 0
var
arrBookmarks
=
ClientData
.
BookMarkData
();
for
(
var
nIndex1
=
0
;
nIndex1
<
arrBookmarks
.
length
;
nIndex1
++
)
{
// Get one bookmar entity
var
oneBookMark
=
arrBookmarks
[
nIndex1
];
if
(
oneBookMark
.
contentid
==
oneContent
.
contentid
)
{
AddErrorPage
(
oneBookMark
.
contentid
,
oneBookMark
.
pageNo
);
}
}
}
}
collection_contents
.
push
({
contentid
:
strContentId
,
contentTitle
:
""
,
contentTitleKana
:
""
,
pages
:
[]
});
}
}
...
...
@@ -924,14 +801,10 @@ Synchronize bookmark with server
*/
function
SyncContent
()
{
// Reset error pages
bookmark_errorPages
=
[];
// Reset error contents
bookmark_errorContent
=
[];
// Reset array of pages
collection_pages
=
[];
// Reset ok checked content
collection_contents
=
[];
// Get bookmarks from local storage
...
...
@@ -947,11 +820,18 @@ function SyncContent() {
// If content is ok + checked
if
(
IsOKCheckedContent
(
oneBookMark
.
contentid
)
==
false
)
{
if
(
!
IsExistContent
(
oneBookMark
.
contentid
))
{
// Add to list of error content
bookmark_errorContent
.
push
({
contentid
:
oneBookMark
.
contentid
});
// Remove bookmark
arrBookmarks
.
splice
(
nIndex
,
1
);
ClientData
.
isChangedBookmark
(
true
);
if
(
avwHasError
())
{
// System error excepting 404
showSystemError
();
return
;
}
else
{
// Add to list of error content
bookmark_errorContent
.
push
({
contentid
:
oneBookMark
.
contentid
});
// Remove bookmark
arrBookmarks
.
splice
(
nIndex
,
1
);
ClientData
.
isChangedBookmark
(
true
);
}
}
// ==================================
// Check existence of content [ end ]
...
...
@@ -970,8 +850,6 @@ function SyncContent() {
// Set back to storage
ClientData
.
BookMarkData
(
arrBookmarks
);
// Call sync pages
//SyncPages();
}
/*
...
...
@@ -992,6 +870,11 @@ function IsExistContent(strContentId) {
if
(
xmlHttpRequest
.
status
==
404
)
{
isExisted
=
false
;
}
else
{
// Show system error
isExisted
=
true
;
// Mark this flag to prevent bookmarks from deleting
showSystemError
();
}
});
return
isExisted
;
}
...
...
abvw/js/contentsearch.js
View file @
bcb0622d
...
...
@@ -98,8 +98,15 @@ $(document).ready(function(){
$
(
'#main-search-tag'
).
click
(
mainSearchTagClickFunction
);
$
(
'#main-search-body'
).
click
(
mainSearchBodyClickFunction
);
$
(
'#control-nextrecord'
).
css
(
'visibility'
,
'hidden'
);
$
(
'#control-nextrecord'
).
css
(
'visibility'
,
'hidden'
);
$
(
window
).
resize
(
function
()
{
if
(
$
(
"#contentDetail"
).
css
(
"display"
)
!=
"none"
)
{
// Refresh panel of detail to center.
$
(
"#contentDetail"
).
center
();
}
});
});
...
...
@@ -387,6 +394,7 @@ function canvasClickFunction(e){
var
contentId
=
$
(
this
).
attr
(
'id'
);
var
outputId
=
contentId
.
substring
(
17
);
var
checkflag
=
false
;
// Set content id for screen: content detail
ClientData
.
contentInfo_contentId
(
outputId
);
...
...
@@ -945,8 +953,8 @@ function drawEditImage(id){
img
.
onload
=
function
(){
var
resizeImg
=
resizeResourceThumbnail
(
img
,
c
.
width
,
c
.
height
);
ctx
.
drawImage
(
img
,
c
.
width
/
2
-
resizeImg
[
0
]
/
2
,
0
,
resizeImg
[
0
],
resizeImg
[
1
]);
$
(
"#loadingIcon"
+
contI
d
).
fadeOut
(
'slow'
,
function
()
{
$
(
'#content-thumbnail'
+
contI
d
).
fadeIn
(
'slow'
);
$
(
"#loadingIcon"
+
i
d
).
fadeOut
(
'slow'
,
function
()
{
$
(
'#content-thumbnail'
+
i
d
).
fadeIn
(
'slow'
);
});
};
}
...
...
@@ -1211,7 +1219,7 @@ function titleClickFunction(e){
home_isMove
=
false
;
return
;
}
var
checkflag
=
false
;
var
contentid
=
$
(
this
).
attr
(
'contentid'
);
// Get image of selected image
var
base64String
=
returnThumbnail
(
contentid
);
...
...
abvw/js/contentview.js
View file @
bcb0622d
...
...
@@ -697,20 +697,90 @@ function checkExistNextPrePage(){
//check next page
if
(
getContent
().
hasNextPage
()){
//$('#nextpage').show();
enable
(
'#nextpage'
);
//enable('#nextpage');
$
(
'#nextpage'
).
unbind
(
'click'
);
$
(
'#nextpage'
).
bind
(
'click'
,
nextPage_click
);
$
(
'#lastpage'
).
unbind
(
'click'
);
$
(
'#lastpage'
).
bind
(
'click'
,
lastPage_click
);
if
(
isTouchDevice
()
==
true
){
$
(
'#nextpage'
).
removeClass
();
$
(
'#nextpage'
).
addClass
(
'next_device'
);
$
(
'#lastpage'
).
removeClass
();
$
(
'#lastpage'
).
addClass
(
'last_device'
);
}
else
{
$
(
'#nextpage'
).
removeClass
();
$
(
'#nextpage'
).
addClass
(
'next'
);
$
(
'#lastpage'
).
removeClass
();
$
(
'#lastpage'
).
addClass
(
'last'
);
}
}
else
{
//$('#nextpage').hide();
disable
(
'#nextpage'
);
//disable('#nextpage');
$
(
'#nextpage'
).
unbind
(
'click'
);
$
(
'#lastpage'
).
unbind
(
'click'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#nextpage'
).
removeClass
();
$
(
'#nextpage'
).
addClass
(
'next_off'
);
$
(
'#lastpage'
).
removeClass
();
$
(
'#lastpage'
).
addClass
(
'last_off'
);
}
else
{
$
(
'#nextpage'
).
removeClass
();
$
(
'#nextpage'
).
addClass
(
'next_off'
);
$
(
'#lastpage'
).
removeClass
();
$
(
'#lastpage'
).
addClass
(
'last_off'
);
}
$
(
'#button_next_canvas'
).
css
(
'opacity'
,
'0'
);
}
//check prev page
if
(
getContent
().
hasPreviousPage
()){
//$('#prevpage').show();
enable
(
'#prevpage'
);
//enable('#prevpage');
$
(
'#prevpage'
).
unbind
(
'click'
);
$
(
'#prevpage'
).
bind
(
'click'
,
prevPage_click
);
$
(
'#firstpage'
).
unbind
(
'click'
);
$
(
'#firstpage'
).
bind
(
'click'
,
firstPage_click
);
if
(
isTouchDevice
()
==
true
){
$
(
'#prevpage'
).
removeClass
();
$
(
'#prevpage'
).
addClass
(
'prev_device'
);
$
(
'#firstpage'
).
removeClass
();
$
(
'#firstpage'
).
addClass
(
'begin_device'
);
}
else
{
$
(
'#prevpage'
).
removeClass
();
$
(
'#prevpage'
).
addClass
(
'prev'
);
$
(
'#firstpage'
).
removeClass
();
$
(
'#firstpage'
).
addClass
(
'begin'
);
}
}
else
{
//$('#prevpage').hide();
disable
(
'#prevpage'
);
//disable('#prevpage');
$
(
'#prevpage'
).
unbind
(
'click'
);
$
(
'#firstpage'
).
unbind
(
'click'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#prevpage'
).
removeClass
();
$
(
'#prevpage'
).
addClass
(
'prev_off'
);
$
(
'#firstpage'
).
removeClass
();
$
(
'#firstpage'
).
addClass
(
'begin_off'
);
}
else
{
$
(
'#prevpage'
).
removeClass
();
$
(
'#prevpage'
).
addClass
(
'prev_off'
);
$
(
'#firstpage'
).
removeClass
();
$
(
'#firstpage'
).
addClass
(
'begin_off'
);
}
$
(
'#button_pre_canvas'
).
css
(
'opacity'
,
'0'
);
}
...
...
@@ -795,12 +865,12 @@ Transition.prototype.flipNextPage = function() {
/* change title of page */
if
(
dataPageTitle
[
getContent
().
pageIndex
]){
if
(
dataPageTitle
[
getContent
().
pageIndex
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
getContent
().
pageIndex
];
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
getContent
().
pageIndex
]
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
/* set end log */
SetEndLog
(
contentID
);
...
...
@@ -841,12 +911,12 @@ Transition.prototype.flipPreviousPage = function() {
/* change title of page */
if
(
dataPageTitle
[
getContent
().
pageIndex
]){
if
(
dataPageTitle
[
getContent
().
pageIndex
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
getContent
().
pageIndex
];
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
getContent
().
pageIndex
]
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
/* set end log */
...
...
@@ -889,12 +959,12 @@ Transition.prototype.flipToPage = function(index) {
/* change title of page */
if
(
dataPageTitle
[
index
]){
if
(
dataPageTitle
[
index
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
index
];
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
index
]
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
/* set end log */
SetEndLog
(
contentID
);
...
...
@@ -927,12 +997,12 @@ Transition.prototype.flipToPage = function(index) {
/* change title of page */
if
(
dataPageTitle
[
index
]){
if
(
dataPageTitle
[
index
]
!=
''
){
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
index
];
document
.
title
=
contentName
+
'_'
+
dataPageTitle
[
index
]
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
}
else
{
document
.
title
=
contentName
;
document
.
title
=
contentName
+
' | '
+
i18nText
(
'sysAppTitle'
)
;
}
/* set end log */
SetEndLog
(
contentID
);
...
...
@@ -1458,7 +1528,9 @@ function disableControlsCopyMemo(){
$
(
'#nextpage'
).
unbind
(
'click'
);
$
(
'#lastpage'
).
unbind
(
'click'
);
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
true
);
if
(
avwUserEnvObj
.
os
!=
"android"
){
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
true
);
}
disable
(
'#txtSearch'
,
'#txtSlider'
);
$
(
'#button_next_canvas'
).
css
(
'display'
,
'none'
);
...
...
@@ -1485,88 +1557,52 @@ function enableControlsCopyMemo(){
$
(
"#nextpage"
).
css
(
'cursor'
,
'pointer'
);
$
(
"#lastpage"
).
css
(
'cursor'
,
'pointer'
);
$
(
"#control_screen"
).
removeClass
();
$
(
"#control_screen_2"
).
removeClass
();
$
(
'#imgHome'
).
bind
(
'click'
,
imgHome_click
);
$
(
'#imgHome'
).
removeClass
();
$
(
'#imgHome'
).
addClass
(
'home'
);
$
(
'#imgBack'
).
bind
(
'click'
,
imgBack_click
);
$
(
'#imgBack'
).
removeClass
();
$
(
'#imgBack'
).
addClass
(
'back'
);
/*list bookmark */
$
(
'#listbookmark'
).
bind
(
'click'
,
showListBookMark
);
$
(
'#listbookmark'
).
removeClass
();
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
}
$
(
'#imgbookmark'
).
bind
(
'click'
,
bookmarkPage
);
$
(
'#imgbookmark'
).
removeClass
();
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
$
(
'#listindex'
).
bind
(
'click'
,
showListPageIndex
);
$
(
'#listindex'
).
removeClass
();
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index'
);
}
$
(
'#copytext'
).
bind
(
'click'
,
showCopyText
);
$
(
'#copytext'
).
removeClass
();
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy'
);
}
/* image memo */
$
(
'#imgmemo'
).
bind
(
'click'
,
handleMemo
);
$
(
'#imgmemo'
).
removeClass
();
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
}
/* image add memo */
$
(
'#imgaddmemo'
).
bind
(
'click'
,
handleAddMemo
);
$
(
'#imgaddmemo'
).
removeClass
();
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
}
$
(
'#imgmarking'
).
bind
(
'click'
,
imgmarking_click
);
$
(
'#imgmarking'
).
removeClass
();
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking'
);
}
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
$
(
'#imgmarkingtoolbar'
).
bind
(
'click'
,
handleDrawCanvas
);
$
(
'#imgmarkingtoolbar'
).
removeClass
();
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar'
);
}
}
$
(
'#firstpage'
).
bind
(
'click'
,
firstPage_click
);
/*$('#firstpage').bind('click',firstPage_click);
$('#firstpage').removeClass();
$('#prevpage').bind('click',prevPage_click);
$('#prevpage').removeClass();
$('#nextpage').bind('click',nextPage_click);
$('#nextpage').removeClass();
$('#lastpage').bind('click',lastPage_click);
$('#lastpage').removeClass();*/
$
(
"#slider_page"
).
slider
(
"option"
,
"disabled"
,
false
);
enable
(
'#txtSearch'
,
'#txtSlider'
);
...
...
@@ -1575,6 +1611,125 @@ function enableControlsCopyMemo(){
$
(
'#button_pre_canvas'
).
css
(
'display'
,
'block'
);
}
if
(
isTouchDevice
()
==
true
){
/* set css for device */
$
(
'#imgHome'
).
addClass
(
'home_device'
);
$
(
'#imgBack'
).
addClass
(
'back_device'
);
/*$('#firstpage').addClass('begin_device');
$('#prevpage').addClass('prev_device');
$('#nextpage').addClass('next_device');
$('#lastpage').addClass('last_device');*/
$
(
"#control_screen"
).
addClass
(
'toolbar_device'
);
$
(
"#control_screen_2"
).
addClass
(
'toolbar_device'
);
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_device'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList_device'
);
}
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy_device'
);
}
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index_device'
);
}
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_device'
);
}
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_device'
);
}
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking_device'
);
}
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_device'
);
}
}
}
else
{
/* set css for PC */
$
(
'#imgHome'
).
addClass
(
'home'
);
$
(
'#imgBack'
).
addClass
(
'back'
);
/*$('#firstpage').addClass('begin');
$('#prevpage').addClass('prev');
$('#nextpage').addClass('next');
$('#lastpage').addClass('last');*/
$
(
"#control_screen"
).
addClass
(
'toolbar'
);
$
(
"#control_screen_2"
).
addClass
(
'toolbar'
);
var
nBookmarkId
=
isExistBookmark
();
if
(
nBookmarkId
==
-
1
){
$
(
'#imgbookmark'
).
addClass
(
'bmAdd'
);
}
else
{
$
(
'#imgbookmark'
).
addClass
(
'bmAdd_hover'
);
}
if
(
isDisplayBookMarkList
==
true
){
$
(
'#listbookmark'
).
addClass
(
'bmList_hover'
);
}
else
{
$
(
'#listbookmark'
).
addClass
(
'bmList'
);
}
if
(
isDisplayCopyText
==
true
){
$
(
'#copytext'
).
addClass
(
'copy_hover'
);
}
else
{
$
(
'#copytext'
).
addClass
(
'copy'
);
}
if
(
isDisplayListIndex
==
true
){
$
(
'#listindex'
).
addClass
(
'index_hover'
);
}
else
{
$
(
'#listindex'
).
addClass
(
'index'
);
}
if
(
ClientData
.
IsDisplayMemo
()
==
true
){
$
(
'#imgmemo'
).
addClass
(
'memoDisplay_hover'
);
}
else
{
$
(
'#imgmemo'
).
addClass
(
'memoDisplay'
);
}
if
(
ClientData
.
IsAddingMemo
()
==
true
){
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd_hover'
);
}
else
{
$
(
'#imgaddmemo'
).
addClass
(
'memoAdd'
);
}
if
(
ClientData
.
IsDisplayMarking
()
==
true
){
$
(
'#imgmarking'
).
addClass
(
'marking_hover'
);
}
else
{
$
(
'#imgmarking'
).
addClass
(
'marking'
);
}
if
(
ClientData
.
serviceOpt_marking
()
==
'Y'
){
if
(
ClientData
.
IsAddingMarking
()
==
true
){
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar_hover'
);
}
else
{
$
(
'#imgmarkingtoolbar'
).
addClass
(
'markingToolbar'
);
}
}
}
checkExistNextPrePage
();
}
...
...
@@ -1766,15 +1921,37 @@ function draw(context) {
/* draw page objects */
getContent
().
currentPage
.
drawPage
(
context
);
/* draw memo */
//drawMemoOnScreen();
context
.
restore
();
initImageCheckMarking
();
};
/* init image if exist marking in page */
function
initImageCheckMarking
(){
/* set draw image if exist */
var
dataMarking
=
ClientData
.
MarkingData
();
var
isExistMarking
=
false
;
for
(
var
nIndex
=
0
;
nIndex
<
dataMarking
.
length
;
nIndex
++
){
if
(
dataMarking
[
nIndex
].
contentid
==
contentID
&&
dataMarking
[
nIndex
].
pageNo
==
changePageIndex
(
getPageIndex
())){
isExistMarking
=
true
;
break
;
}
}
/* init image display or not */
if
(
isExistMarking
==
true
){
$
(
'#divCheckExistMarking'
).
show
();
}
else
{
$
(
'#divCheckExistMarking'
).
hide
();
}
}
var
leftCanvas
=
0
;
var
topCanvas
=
0
;
...
...
@@ -1831,7 +2008,8 @@ function flip() {
width
=
width
*
size
;
}
if
(
userScale
!=
1
&&
width
<
canvas
.
width
){
if
(
userScale
!=
1
&&
width
<
canvas
.
width
){
width
=
width
*
userScale
;
if
(
width
>
canvas
.
width
){
//var size = canvas.width / width;
...
...
@@ -1840,7 +2018,7 @@ function flip() {
}
}
else
if
(
userScale
!=
1
&&
height
<
canvas
.
height
){
height
=
width
*
userScale
;
if
(
height
>
canvas
.
height
){
...
...
@@ -2038,8 +2216,8 @@ var openPopUp = function(mediaType, actionType, id, imageUrl, x, y, w, h, visibl
this
.
setup
(
mediaType
,
actionType
,
id
,
imageUrl
,
x
,
y
,
w
,
h
,
visible
,
null
,
null
);
this
.
action
=
function
()
{
isOpenPopUpText
=
true
;
var
pt1
=
imageToScreen
(
x
,
y
);
OpenPopupText
(
pt1
.
x
,
pt1
.
y
+
h
/
2
,
content
,
$
(
'#dialogPopUp'
),
$
(
'#arrow'
));
var
pt1
=
imageToScreen
(
x
,
y
+
h
/
2
);
OpenPopupText
(
pt1
.
x
,
pt1
.
y
,
content
,
$
(
'#dialogPopUp'
),
$
(
'#arrow'
));
}
};
openPopUp
.
prototype
=
new
PageObject
();
...
...
@@ -2282,6 +2460,7 @@ function createAudio(audio,type){
' </audio>'
);
}
}
else
{
if
(
avwUserEnvObj
.
browser
==
'firefox'
){
$
(
'#playaudio'
).
html
(
...
...
@@ -2294,15 +2473,19 @@ function createAudio(audio,type){
' </audio>'
);
}
}
}
else
if
(
type
==
"1"
){
/* play all page */
TypeAudio1
=
type
;
srcAudioType1
=
audio
;
srcAudioType1
=
audio
;
if
(
document
.
getElementById
(
"play_audio_1"
)
!=
undefined
){
//document.getElementById("play_audio_1").load();
// document.getElementById("play_audio_1").load();
// document.getElementById("play_audio_1").play();
}
else
{
if
(
ClientData
.
userOpt_musicMode
()
==
"1"
){
if
(
avwUserEnvObj
.
browser
==
'firefox'
){
...
...
@@ -2311,11 +2494,11 @@ function createAudio(audio,type){
);
}
else
{
$
(
'#playaudioallpage'
).
html
(
' <audio id="play_audio_1" loop="loop" autoplay
="autoplay"
>'
+
' <audio id="play_audio_1" loop="loop" autoplay
="autoplay"
>'
+
' <source src="'
+
audio
+
'&key='
+
(
new
Date
()).
toIdString
()
+
'" type="audio/mpeg" />'
+
' </audio>'
);
}
}
}
else
{
if
(
avwUserEnvObj
.
browser
==
'firefox'
){
$
(
'#playaudioallpage'
).
html
(
...
...
@@ -2323,13 +2506,19 @@ function createAudio(audio,type){
);
}
else
{
$
(
'#playaudioallpage'
).
html
(
' <audio id="play_audio_1" autoplay =
"autoplay"
>'
+
' <audio id="play_audio_1" autoplay =
"autoplay"
>'
+
' <source src="'
+
audio
+
'&key='
+
(
new
Date
()).
toIdString
()
+
'" type="audio/mpeg" />'
+
' </audio>'
);
}
}
}
}
//playAllAudio();
// if(document.getElementById("play_audio_1") != undefined){
// document.getElementById("play_audio_1").pause();
// document.getElementById("play_audio_1").play();
// }
}
}
else
if
(
type
==
"2"
){
/* play on page */
stopAllAudio
();
...
...
@@ -2527,6 +2716,9 @@ function sizingNotFull(width, height) {
changeScale
(
userScale
);
flip
();
}
/* move image check marking*/
$
(
'#divCheckExistMarking'
).
css
(
'top'
,
'70px'
);
};
/* Adjust Component size */
...
...
@@ -2550,6 +2742,9 @@ function sizingFullSize(width, height) {
changeScale
(
userScale
);
flip
();
}
/* move image check marking*/
$
(
'#divCheckExistMarking'
).
css
(
'top'
,
'5px'
);
};
/* zoom video */
...
...
@@ -2665,8 +2860,6 @@ function trackTransforms(ctx){
function
zoomIn
()
{
userScale
+=
scaleDelta
;
if
(
userScale
>
4
){
userScale
=
4
;
}
...
...
@@ -2680,10 +2873,20 @@ function zoomIn() {
zoomVideo
();
}
checkDisableButtonZoom
();
/* close dialog popuptext */
closeDialogPopUpText
();
};
/* close dialog pop */
function
closeDialogPopUpText
(){
if
(
isOpenPopUpText
==
true
){
isOpenPopUpText
=
false
;
ClosePopupText
();
}
}
function
checkDisableButtonZoom
(){
if
(
userScale
>=
4
){
$
(
'#zoomin'
).
removeClass
();
...
...
@@ -2694,7 +2897,11 @@ function checkDisableButtonZoom(){
$
(
'#zoomin'
).
bind
(
'click'
,
zoomIn
);
$
(
'#zoomin'
).
removeClass
();
$
(
'#zoomin'
).
addClass
(
'expansion'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#zoomin'
).
addClass
(
'expansion_device'
);
}
else
{
$
(
'#zoomin'
).
addClass
(
'expansion'
);
}
$
(
"#zoomin"
).
css
(
'cursor'
,
'pointer'
);
}
...
...
@@ -2707,41 +2914,29 @@ function checkDisableButtonZoom(){
$
(
'#zoomout'
).
bind
(
'click'
,
zoomOut
);
$
(
'#zoomout'
).
removeClass
();
$
(
'#zoomout'
).
addClass
(
'reduction'
);
if
(
isTouchDevice
()
==
true
){
$
(
'#zoomout'
).
addClass
(
'reduction_device'
);
}
else
{
$
(
'#zoomout'
).
addClass
(
'reduction'
);
}
$
(
"#zoomout"
).
css
(
'cursor'
,
'pointer'
);
}
}
function
checkDisableButtonZoom1
(){
if
(
userScale
>=
4
){
$
(
'#zoomin'
).
unbind
(
'click'
);
$
(
'#zoomin'
).
removeClass
();
$
(
'#zoomin'
).
addClass
(
'expansion_off'
);
$
(
"#zoomin"
).
css
(
'cursor'
,
'default'
);
}
else
{
$
(
'#zoomin'
).
unbind
(
'click'
);
$
(
'#zoomin'
).
bind
(
'click'
,
zoomIn
);
$
(
'#zoomin'
).
removeClass
();
$
(
'#zoomin'
).
addClass
(
'expansion'
);
$
(
"#zoomin"
).
css
(
'cursor'
,
'pointer'
);
}
if
(
userScale
<=
1
){
$
(
'#zoomout'
).
unbind
(
'click'
);
$
(
'#zoomout'
).
removeClass
();
$
(
'#zoomout'
).
addClass
(
'reduction_off'
);
$
(
"#zoomout"
).
css
(
'cursor'
,
'default'
);
if
(
userScale
==
1
){
$
(
'#zoomfit'
).
removeClass
();
$
(
'#zoomfit'
).
addClass
(
'fit_off'
);
$
(
"#zoomfit"
).
css
(
'cursor'
,
'default'
);
}
else
{
$
(
'#zoom
ou
t'
).
unbind
(
'click'
);
$
(
'#zoom
out'
).
bind
(
'click'
,
zoomOu
t
);
$
(
'#zoom
fi
t'
).
unbind
(
'click'
);
$
(
'#zoom
fit'
).
bind
(
'click'
,
screenFi
t
);
$
(
'#zoomout'
).
removeClass
();
$
(
'#zoomout'
).
addClass
(
'reduction'
);
$
(
"#zoomout"
).
css
(
'cursor'
,
'pointer'
);
$
(
'#zoomfit'
).
removeClass
();
if
(
isTouchDevice
()
==
true
){
$
(
'#zoomfit'
).
addClass
(
'fit_device'
);
}
else
{
$
(
'#zoomfit'
).
addClass
(
'fit'
);
}
$
(
"#zoomfit"
).
css
(
'cursor'
,
'pointer'
);
}
}
...
...
@@ -2760,6 +2955,9 @@ function zoomOut() {
}
checkDisableButtonZoom
();
/* close dialog popuptext */
closeDialogPopUpText
();
};
/* restore screen size */
...
...
@@ -2779,6 +2977,9 @@ function screenFit() {
zoomVideo
();
checkDisableButtonZoom
();
/* close dialog popuptext */
closeDialogPopUpText
();
};
...
...
@@ -2800,18 +3001,20 @@ function changeScale(scale) {
if
(
width
>
canvas
.
width
)
{
width
=
canvas
.
width
;
height
=
width
/
aspect
;
}
if
(
height
>
canvas
.
height
){
height
=
canvas
.
height
;
width
=
height
/
aspect
;
}
}
}
else
{
width
=
canvas
.
width
;
height
=
width
/
aspect
;
}
if
(
width
<
canvas
.
width
){
if
(
height
>
canvas
.
height
){
var
size
=
canvas
.
height
/
height
;
height
=
canvas
.
height
;
width
=
width
*
size
;
}
if
(
width
<
canvas
.
width
){
//if(width >= height){
width
=
width
*
scale
;
...
...
@@ -2825,7 +3028,7 @@ function changeScale(scale) {
//}else if(height <= canvas.height){
}
else
if
(
height
<
canvas
.
height
){
height
=
height
*
scale
;
if
(
height
>
canvas
.
height
){
...
...
@@ -3070,5 +3273,5 @@ $(function () {
}
//$(document).bind('touchmove', function (e) { e.preventDefault(); });
}
}
});
\ No newline at end of file
...
...
abvw/js/contentview_Gomu.js
View file @
bcb0622d
...
...
@@ -25,10 +25,11 @@ function ShowEraser(targetDiv) {
//$('#dlgGomu').dialog("open");
//$(".ui-dialog-titlebar").hide();
//lockLayout();
$
(
'#dlgGomu'
).
fadeIn
(
'medium'
,
function
(){
$
(
'#dlgGomu'
).
draggable
();
});
// $('#dlgGomu').fadeIn('medium', function(){
// $('#dlgGomu').draggable();
// });
$
(
'#dlgGomu'
).
show
();
$
(
'#dlgGomu'
).
draggable
();
Eraser_SetDefaultValue
();
}
// Set default value for easer.
...
...
@@ -192,14 +193,32 @@ Event groups [ end ]
*/
function
touchStart_BtnOk_Gomu
(
e
){
e
.
preventDefault
();
$
(
'#dlgGomu'
).
draggable
(
"destroy"
);
dlgGomu_dspOK_click
();
}
function
touchStart_BtnCancel_Gomu
(
e
){
e
.
preventDefault
();
$
(
'#dlgGomu'
).
draggable
(
"destroy"
);
dlgGomu_dspCancel_click
();
}
// Setting dialog
$
(
function
()
{
// ---------------------------------
// Setup for easer [start]
// ---------------------------------
if
(
isTouchDevice
()
==
true
){
document
.
getElementById
(
'dlgGomu_dspOK'
).
addEventListener
(
'touchstart'
,
touchStart_BtnOk_Gomu
,
false
);
document
.
getElementById
(
'dlgGomu_dspCancel'
).
addEventListener
(
'touchstart'
,
touchStart_BtnCancel_Gomu
,
false
);
}
$
(
"#dlgGomu_dspOK"
).
click
(
dlgGomu_dspOK_click
);
$
(
"#dlgGomu_dspCancel"
).
click
(
dlgGomu_dspCancel_click
);
...
...
@@ -209,12 +228,12 @@ $(function () {
$
(
"#dlgGomu_rdo3"
).
click
(
dlgGomu_rdo3_click
);
$
(
"#dlgGomu_rdo4"
).
click
(
dlgGomu_rdo4_click
);
$
(
"#dlgGomu_rdo1_text"
).
click
(
dlgGomu_rdo1_text_click
);
$
(
"#dlgGomu_rdo2_text"
).
click
(
dlgGomu_rdo2_text_click
);
$
(
"#dlgGomu_rdo3_text"
).
click
(
dlgGomu_rdo3_text_click
);
$
(
"#dlgGomu_rdo4_text"
).
click
(
dlgGomu_rdo4_text_click
);
//
$("#dlgGomu_rdo1_text").click(dlgGomu_rdo1_text_click);
//
$("#dlgGomu_rdo2_text").click(dlgGomu_rdo2_text_click);
//
$("#dlgGomu_rdo3_text").click(dlgGomu_rdo3_text_click);
// $("#dlgGomu_rdo4_text").click(dlgGomu_rdo4_text_click);
$
(
'#dlgGomu_rdo1_text'
).
click
()
//
$('#dlgGomu_rdo1_text').click()
// ---------------------------------
// Setup for easer [ end ]
// ---------------------------------
...
...
abvw/js/contentview_Maker.js
View file @
bcb0622d
...
...
@@ -54,13 +54,28 @@ function ShowMaker(targetId){
});
i18nReplaceText
();
maker_targetDiv
.
fadeIn
(
'medium'
,
function
(){
//lockLayout();
maker_targetDiv
.
draggable
();
});
// maker_targetDiv.fadeIn('medium',function(){
// //lockLayout();
// maker_targetDiv.draggable();
// }); maker_targetDiv.show();
maker_targetDiv
.
draggable
({
revert
:
false
});
Maker_handleColorPickerEvent
();
}
function
touchStart_BtnOk_Maker
(
e
){
e
.
preventDefault
();
maker_targetDiv
.
draggable
(
"destroy"
);
Maker_dspOK_click
();
}
function
touchStart_BtnCancel_Maker
(
e
){
e
.
preventDefault
();
maker_targetDiv
.
draggable
(
"destroy"
);
Maker_dspCancel_click
();
}
function
Maker_handleColorPickerEvent
(){
//$('.colorpicker').live('mouseenter',Maker_colorPickerMouseEnterFunction);
...
...
@@ -72,6 +87,8 @@ function Maker_handleColorPickerEvent(){
$
(
'.colorpicker'
).
unbind
(
'mouseleave'
);
$
(
'#makerColorwrapper'
).
unbind
(
'mouseleave'
);
document
.
getElementById
(
'Maker_btnOk'
).
addEventListener
(
'touchstart'
,
touchStart_BtnOk_Maker
,
false
);
document
.
getElementById
(
'Maker_btnCancel'
).
addEventListener
(
'touchstart'
,
touchStart_BtnCancel_Maker
,
false
);
}
else
{
//alert('here');
...
...
abvw/js/contentview_Marking.js
View file @
bcb0622d
...
...
@@ -140,9 +140,9 @@ function dlgMarking_dspPgClear_click() {
function
dlgMarking_imgPen_click
()
{
// Choose pen
$
(
"#dlgMarking_imgMaker"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgMaker"
).
removeClass
();
$
(
"#dlgMarking_imgPen"
).
addClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgEraser"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgEraser"
).
removeClass
();
ClientData
.
MarkingType
(
"pen"
);
markingType
=
"pen"
;
...
...
@@ -159,8 +159,8 @@ function dlgMarking_imgPenOption_click() {
function
dlgMarking_imgMaker_click
()
{
// Choose maker
$
(
"#dlgMarking_imgMaker"
).
addClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgPen"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgEraser"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgPen"
).
removeClass
();
$
(
"#dlgMarking_imgEraser"
).
removeClass
();
ClientData
.
MarkingType
(
"maker"
);
markingType
=
"maker"
;
...
...
@@ -176,8 +176,8 @@ function dlgMarking_imgMakerOption_click() {
}
function
dlgMarking_imgEraser_click
()
{
// Choose eraser
$
(
"#dlgMarking_imgMaker"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgPen"
).
removeClass
(
'toolbar_icon_on'
);
$
(
"#dlgMarking_imgMaker"
).
removeClass
();
$
(
"#dlgMarking_imgPen"
).
removeClass
();
$
(
"#dlgMarking_imgEraser"
).
addClass
(
'toolbar_icon_on'
);
ClientData
.
MarkingType
(
"eraser"
);
...
...
@@ -296,10 +296,10 @@ function ShowMarking() {
//$('#dlgMarking').css('height', '300px');
//$('#dlgMarking').dialog("open");
$
(
'#dlgMarking'
).
show
();
//$('#dlgMarking').fadeIn('fast');
$
(
'#dlgMarking'
).
css
(
'top'
,
'40px'
);
$
(
'#dlgMarking'
).
css
(
'top'
,
'40px'
);
$
(
'#dlgMarking'
).
css
(
'left'
,
'10px'
);
$
(
'#dlgMarking'
).
show
();
//$('#dlgMarking').fadeIn('fast');
// $('#dlgMarking').center();
// $('#dlgMarking').top();
...
...
abvw/js/contentview_Memo.js
View file @
bcb0622d
...
...
@@ -123,6 +123,7 @@ function AddMemo(contentId,pageNo,targetId, posX, posY, callback) {
//targetDiv.dialog({width: 466, height: 390, modal: true, position: [targetX, targetY], resizable: false});
//targetDiv.parent().removeClass('ui-draggable');
$
(
"#overlay"
).
show
();
disableControlsCopyMemo
();
targetDiv
.
css
(
'z-index'
,
'1005'
);
targetDiv
.
css
(
'top'
,
targetY
);
targetDiv
.
css
(
'left'
,
targetX
-
(
$
(
'#memoWrapper'
).
width
()
/
2
));
...
...
@@ -147,6 +148,7 @@ function EditMemo(index, posXPlus, posYPlus, targetId, callback){
//targetDiv.dialog({width: 466, height: 390, modal: true, position: [targetX, targetY], resizable: false});
//targetDiv.parent().removeClass('ui-draggable');
$
(
"#overlay"
).
show
();
disableControlsCopyMemo
();
targetDiv
.
css
(
'z-index'
,
'1005'
);
var
pt
=
imageToScreen
(
targetX
,
targetY
);
...
...
@@ -173,6 +175,7 @@ function CopyMemo(index,contentId,pageNo,targetId, posX, posY, callback){
//targetDiv.dialog({width: 466, height: 390, modal: true, position: [targetX, targetY], resizable: false});
//targetDiv.parent().removeClass('ui-draggable');
$
(
"#overlay"
).
show
();
disableControlsCopyMemo
();
targetDiv
.
css
(
'z-index'
,
'1005'
);
targetDiv
.
css
(
'top'
,
targetY
);
targetDiv
.
css
(
'left'
,
targetX
-
(
$
(
'#memoWrapper'
).
width
()
/
2
));
...
...
abvw/js/contentview_Paint.js
View file @
bcb0622d
...
...
@@ -189,7 +189,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
// 左上に描画する場合
...
...
@@ -212,7 +212,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -234,7 +234,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -258,7 +258,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -282,7 +282,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -304,7 +304,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -317,7 +317,7 @@ function drawMove(coors, context_draw) {
}
}
else
{
if
(
sy
>
coors
.
y
)
{
/*
context_draw.globalCompositeOperation = 'destination-out';
/*
context_draw.globalCompositeOperation = 'destination-out';
context_draw.moveTo(ptStart[2].x, ptStart[2].y);
context_draw.lineTo(ptStart[3].x, ptStart[3].y);
context_draw.lineTo(ptEnd[0].x, ptEnd[0].y);
...
...
@@ -326,7 +326,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -346,7 +346,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -366,7 +366,7 @@ function drawMove(coors, context_draw) {
context_draw.lineCap = 'butt';
context_draw.fillStyle = "#" + makerColor;
context_draw.fill();
context_draw.globalCompositeOperation = '
source-ov
er';
context_draw.globalCompositeOperation = '
light
er';
context_draw.closePath();
context_draw.beginPath();*/
...
...
@@ -441,7 +441,7 @@ function drawPoint(coors, context_draw) {
context_draw.lineCap = 'square';
context_draw.strokeStyle = "#" + makerColor;
context_draw.stroke();
context_draw.globalCompositeOperation = '
source-ov
er';*/
context_draw.globalCompositeOperation = '
light
er';*/
context_draw
.
lineCap
=
"square"
;
context_draw
.
lineWidth
=
makerSize
;
...
...
abvw/js/contentview_Pen.js
View file @
bcb0622d
...
...
@@ -25,8 +25,7 @@ var pen_chooseColor;
function
ShowPen
(
targetId
)
{
pen_targetDiv
=
targetId
;
pen_targetDiv
.
html
(
''
);
pen_targetDiv
.
children
().
remove
();
targetId
.
append
(
'<div id="panel-pen" class="rayermenu1">'
+
' <div id="panel-pen-size">'
...
...
@@ -58,13 +57,30 @@ function ShowPen(targetId) {
i18nReplaceText
();
// pen_targetDiv.dialog({ width: 510, height: 390, modal: true });
pen_targetDiv
.
fadeIn
(
'medium'
,
function
(){
//lockLayout();
pen_targetDiv
.
draggable
({
containment
:
"#containment-wrapper"
,
scroll
:
false
});
});
// pen_targetDiv.fadeIn('medium',function(){
// //lockLayout();
// pen_targetDiv.draggable({ containment: "#containment-wrapper", scroll: false });
// }); pen_targetDiv.show();
//pen_targetDiv.draggable({ containment: "#Pen_btnOk", scroll: false });
pen_targetDiv
.
draggable
({
revert
:
false
});
Pen_handleColorPickerEvent
();
}
function
touchStart_BtnOk_Pen
(
e
){
e
.
preventDefault
();
pen_targetDiv
.
draggable
(
"destroy"
);
Pen_dspOK_click
();
}
function
touchStart_BtnCancel_Pen
(
e
){
e
.
preventDefault
();
pen_targetDiv
.
draggable
(
"destroy"
);
Pen_dspCancel_click
();
}
function
Pen_handleColorPickerEvent
()
{
...
...
@@ -77,10 +93,11 @@ function Pen_handleColorPickerEvent() {
$
(
'.colorpicker'
).
unbind
(
'mouseenter'
);
$
(
'.colorpicker'
).
unbind
(
'mouseleave'
);
$
(
'#penColorwrapper'
).
unbind
(
'mouseleave'
);
document
.
getElementById
(
'Pen_btnOk'
).
addEventListener
(
'touchstart'
,
touchStart_BtnOk_Pen
,
false
);
document
.
getElementById
(
'Pen_btnCancel'
).
addEventListener
(
'touchstart'
,
touchStart_BtnCancel_Pen
,
false
);
}
else
{
//alert('here');
$
(
'.colorpicker'
).
unbind
(
'mouseenter'
);
$
(
'.colorpicker'
).
unbind
(
'mouseleave'
);
$
(
'#penColorwrapper'
).
unbind
(
'mouseleave'
);
...
...
@@ -90,7 +107,7 @@ function Pen_handleColorPickerEvent() {
$
(
'#penColorwrapper'
).
bind
(
'mouseleave'
,
Pen_colorWrapperMouseLeaveFunction
);
}
$
(
'#Pen_btnOk'
).
live
(
'click'
,
Pen_dspOK_click
);
$
(
'#Pen_btnOk'
).
live
(
'click'
,
Pen_dspOK_click
);
$
(
'#Pen_btnCancel'
).
live
(
'click'
,
Pen_dspCancel_click
);
Pen_SetDefaultValue
();
...
...
@@ -108,9 +125,9 @@ function Pen_handleColorPickerEvent() {
$
(
'.colorpicker'
).
live
(
'click'
,
Pen_colorPickerClickFunction
);
//$('#penColorwrapper').live('mouseleave', Pen_colorWrapperMouseLeaveFunction);
$
(
"#avw-sys-modal"
).
click
(
function
()
{
pen_targetDiv
.
fadeOut
(
'medium'
,
function
(){
//unlockLayout();
}
);
//
pen_targetDiv.fadeOut('medium',function(){
//
//
unlockLayout();
// }); pen_targetDiv.show(
);
});
}
...
...
@@ -265,8 +282,7 @@ function Pen_rdo4_click() {
}
// Event of button OK
function
Pen_dspOK_click
()
{
function
Pen_dspOK_click
()
{
// Set selected value to local storage
var
typeValue
=
undefined
;
...
...
abvw/js/contentview_PopupText.js
View file @
bcb0622d
...
...
@@ -88,7 +88,7 @@ function OpenPopupText(posX, posY, content, dialogDiv, arrowDiv) {
break
;
}
dialogDiv
.
css
(
"left"
,
left_dialog
+
"px"
);
dialogDiv
.
css
(
"top"
,
top_dialog
+
"px"
);
dialogDiv
.
css
(
"top"
,
(
top_dialog
+
10
)
+
"px"
);
}
/*
...
...
abvw/js/header.js
View file @
bcb0622d
/// <reference path="../common/js/avweb.js" />
/// <reference path="../common/js/common.js" />
/// <reference path="../common/js/i18n.js" />
/// <reference path="../common/js/jquery-1.8.1.min.js" />
/// <reference path="../common/js/jquery-ui-1.8.23.custom.min.js" />
/// <reference path="../common/js/jquery.toastmessage.js" />
var
isHoverOn
=
false
;
$
(
document
).
ready
(
function
()
{
if
(
!
avwCheckLogin
(
ScreenIds
.
Login
))
return
;
// Set event to prevent leave
avwSetLogoutNortice
();
//avwSetLogoutNortice();
ToogleLogoutNortice
();
//Toggle Searchbox
$
(
'input#searchbox-key'
).
click
(
toggleSearchPanel
);
...
...
@@ -273,13 +277,14 @@ function logoutFunction() {
}
else
{
if
(
ClientData
.
userOpt_logoutMode
()
==
0
)
{
// Logout with backup
lockLayout
();
DoBackup
();
}
else
if
(
ClientData
.
userOpt_logoutMode
()
==
1
)
{
// Logout without backup
// Do nothing
}
// Logout
webLogoutEvent
();
//
webLogoutEvent();
}
}
}
...
...
@@ -337,6 +342,9 @@ function confirmWithoutBackupFunction(e) {
function
confirmWithBackupFunction
(
e
)
{
e
.
preventDefault
();
var
remember
=
$
(
'#chkRememberBackup'
).
attr
(
'checked'
);
unlockLayout
();
$
(
'#dlgConfirmBackup1'
).
css
(
'z-index'
,
'99'
);
lockLayout
();
if
(
remember
==
'checked'
){
ClientData
.
userOpt_bkConfirmFlg
(
0
);
// Do not show dialog in next time
...
...
@@ -348,7 +356,7 @@ function confirmWithBackupFunction(e) {
}
ClientData
.
userOpt_logoutMode
(
0
);
// In next time, if choose: [do not show dialog], will backup and logout
webLogoutEvent
();
//
webLogoutEvent();
}
//Confirm Back Up Ok
...
...
@@ -369,35 +377,44 @@ function DoBackup() {
ClientData
.
isChangedBookmark
(
false
);
ClientData
.
isChangedMarkingData
(
false
);
ClientData
.
isChangedMemo
(
false
);
alert
(
i18nText
(
'msgBackupSuccess'
));
// // Show message: msgBackupSuccess
// $().toastmessage({ position: 'middle-center' });
// $().toastmessage('showToast', {
// type: 'success',
// sticky: true,
// text: i18nText('msgBackupSuccess')
// });
//alert(i18nText('msgBackupSuccess'));
// Show message: msgBackupSuccess
$
().
toastmessage
({
position
:
'middle-center'
});
$
().
toastmessage
(
'showToast'
,
{
type
:
'success'
,
sticky
:
true
,
text
:
i18nText
(
'msgBackupSuccess'
),
});
$
(
'.toast-position-middle-center'
).
css
(
'width'
,
'500px'
);
$
(
'.toast-position-middle-center'
).
css
(
'margin-left'
,
'-250px'
);
$
(
'.toast-item-close'
).
live
(
'click'
,
webLogoutEvent
);
}
else
{
alert
(
i18nText
(
'msgBackupFailed'
));
// // Show error message: msgBackupFailed
// $().toastmessage({ position: 'middle-center' });
// $().toastmessage('showToast', {
// type: 'error',
// sticky: true,
// text: i18nText('msgBackupFailed')
// });
//alert(i18nText('msgBackupFailed'));
// Show error message: msgBackupFailed
$
().
toastmessage
({
position
:
'middle-center'
});
$
().
toastmessage
(
'showToast'
,
{
type
:
'error'
,
sticky
:
true
,
text
:
i18nText
(
'msgBackupFailed'
)
});
$
(
'.toast-position-middle-center'
).
css
(
'width'
,
'500px'
);
$
(
'.toast-position-middle-center'
).
css
(
'margin-left'
,
'-250px'
);
$
(
'.toast-item-close'
).
live
(
'click'
,
webLogoutEvent
);
}
},
function
(
a
,
b
,
c
)
{
alert
(
i18nText
(
'msgBackupFailed'
));
// // Show error message: msgBackupFailed
// $().toastmessage({ position: 'middle-center' });
// $().toastmessage('showToast', {
// type: 'error',
// sticky: true,
// text: i18nText('msgBackupFailed')
// });
//alert(i18nText('msgBackupFailed'));
// Show error message: msgBackupFailed
$
().
toastmessage
({
position
:
'middle-center'
});
$
().
toastmessage
(
'showToast'
,
{
type
:
'error'
,
sticky
:
true
,
text
:
i18nText
(
'msgBackupFailed'
)
});
$
(
'.toast-position-middle-center'
).
css
(
'width'
,
'500px'
);
$
(
'.toast-position-middle-center'
).
css
(
'margin-left'
,
'-250px'
);
$
(
'.toast-item-close'
).
live
(
'click'
,
webLogoutEvent
);
});
}
\ No newline at end of file
abvw/js/history.js
View file @
bcb0622d
...
...
@@ -38,6 +38,7 @@ var totalPage;
var
contentViewData
=
[];
var
noRecordFlg
=
false
;
var
home_isMove
=
false
;
var
history_contentTitleKana
=
[];
$
(
document
).
ready
(
function
(){
...
...
@@ -88,6 +89,13 @@ $(document).ready(function(){
//$('.button-details').live('touchstart', readSubmenuFunction);
$
(
'.button-details'
).
live
(
'touchend'
,
readSubmenuFunction
);
$
(
'.button-details'
).
live
(
'touchmove'
,
function
()
{
home_isMove
=
true
;
});
$
(
window
).
resize
(
function
()
{
if
(
$
(
"#contentDetail"
).
css
(
"display"
)
!=
"none"
)
{
// Refresh panel of detail to center.
$
(
"#contentDetail"
).
center
();
}
});
});
//Call API
...
...
@@ -1122,6 +1130,20 @@ function syncReadingContent(){
}
/*
Get content title kana if it existed
*/
function
getContentNameKana
(
strContentId
)
{
var
strContentNameKana
=
null
;
for
(
var
nIndex
=
0
;
nIndex
<
history_contentTitleKana
.
length
;
nIndex
++
)
{
if
(
history_contentTitleKana
[
nIndex
].
contentId
==
strContentId
)
{
strContentNameKana
=
history_contentTitleKana
[
nIndex
].
contentNameKana
;
break
;
}
}
return
strContentNameKana
;
}
/*
Check content whether existed or not
*/
function
IsExistContent
(
strContentId
)
{
...
...
@@ -1134,6 +1156,7 @@ function IsExistContent(strContentId) {
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webGetContent"
,
'GET'
,
params
,
function
(
data
)
{
isExisted
=
true
;
history_contentTitleKana
.
push
({
contentId
:
strContentId
,
contentNameKana
:
data
.
contentData
.
contentNameKana
});
},
function
(
xmlHttpRequest
,
txtStatus
,
errorThrown
)
{
if
(
xmlHttpRequest
.
status
==
404
)
{
...
...
@@ -1341,22 +1364,32 @@ function formatOriginalPublishDate(date){
return
resultDate
;
}
function
returnContentTitleKana
(
id
){
var
params
=
{
contentId
:
id
,
sid
:
ClientData
.
userInfo_sid
(),
getType
:
1
}
function
returnContentTitleKana
(
id
)
{
var
titleKana
;
// Get all pages of content
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webGetContent"
,
'GET'
,
params
,
// Get title kana from existed contents
titleKana
=
getContentNameKana
(
id
);
if
(
titleKana
!=
null
)
{
// Skip this case
}
else
{
var
params
=
{
contentId
:
id
,
sid
:
ClientData
.
userInfo_sid
(),
getType
:
1
}
// Get all pages of content
avwCmsApiSync
(
ClientData
.
userInfo_accountPath
(),
"webGetContent"
,
'GET'
,
params
,
function
(
data
)
{
// Success
titleKana
=
data
.
contentData
.
contentNameKana
;
},
null
);
return
titleKana
;
titleKana
=
data
.
contentData
.
contentNameKana
;
},
null
);
}
return
titleKana
;
}
function
resizeResourceThumbnail
(
mg
,
width
,
height
)
{
...
...
abvw/js/home.js
View file @
bcb0622d
...
...
@@ -20,8 +20,8 @@
//----Constant-----------//
var
DEFAULT_DISP_NUMBER_RECORD_FROM
=
1
;
var
DEFAULT_DISP_NUMBER_RECORD_TO
=
15
;
var
DEFAULT_SORT_TYPE
=
'
1
'
;
var
DEFAULT_SORT_ORDER
=
'
1
'
;
var
DEFAULT_SORT_TYPE
=
'
3
'
;
var
DEFAULT_SORT_ORDER
=
'
2
'
;
var
DEFAULT_SEARCH_DIVISION
=
0
;
var
DEFAULT_IMG_OPTION_MEMO
=
'img/list/pic_1.png'
;
...
...
@@ -49,9 +49,9 @@ $(document).ready(function () {
if
(
!
avwCheckLogin
(
ScreenIds
.
Login
))
{
return
;
}
document
.
title
=
i18nText
(
'dspHome'
)
+
' | '
+
i18nText
(
'sysAppTitle'
);
// Set bookmark screen
ClientData
.
BookmarkScreen
(
ScreenIds
.
Home
);
...
...
@@ -59,12 +59,12 @@ $(document).ready(function () {
RegisterLog
();
//Sync Data
if
(
ClientData
.
ReadingContentIds
()
==
null
||
ClientData
.
ReadingContentIds
()
==
'undefined'
||
ClientData
.
ReadingContentIds
().
length
==
0
){
ClientData
.
common_contentDataChkFlg
(
false
);
}
else
{
syncContentData
();
}
if
(
ClientData
.
ReadingContentIds
()
==
null
||
ClientData
.
ReadingContentIds
()
==
'undefined'
||
ClientData
.
ReadingContentIds
().
length
==
0
)
{
ClientData
.
common_contentDataChkFlg
(
false
);
}
else
{
syncContentData
();
}
//Toggle TreeView Disp
handleTreeViewDisp
();
...
...
@@ -98,8 +98,8 @@ $(document).ready(function () {
//$('.dialog').live('touchstart', openSubMenuDialogFunction);
$
(
'.dialog'
).
live
(
'touchend'
,
openSubMenuDialogFunction
);
$
(
'.dialog'
).
live
(
'touchmove'
,
function
()
{
home_isMove
=
true
;
});
//Render Genre TreeView
$
(
'#lnkbtnGenre'
).
click
(
genreSelectFunction
);
...
...
@@ -125,15 +125,21 @@ $(document).ready(function () {
$
(
'#control-sort-releasedate'
).
click
(
sortByReleaseDateFunction
);
//Go To Details Page
$
(
'.button-details'
).
live
(
'click'
,
readSubmenuFunction
);
$
(
'.button-details'
).
live
(
'click'
,
readSubmenuFunction
);
//$('.button-details').live('touchstart', readSubmenuFunction);
$
(
'.button-details'
).
live
(
'touchend'
,
readSubmenuFunction
);
$
(
'.button-details'
).
live
(
'touchmove'
,
function
()
{
home_isMove
=
true
;
});
$
(
'#dlgSubMenu'
).
hover
(
subMenuHoverFunction
,
subMenuHoverOffFunction
);
$
(
'#dlgSubMenu'
).
hover
(
subMenuHoverFunction
,
subMenuHoverOffFunction
);
$
(
'body'
).
click
(
bodyHomeClickFunction
);
$
(
window
).
resize
(
function
()
{
if
(
$
(
"#contentDetail"
).
css
(
"display"
)
!=
"none"
)
{
// Refresh panel of detail to center.
$
(
"#contentDetail"
).
center
();
}
});
});
function
subMenuHoverFunction
(){
...
...
@@ -453,7 +459,9 @@ function genreSelectFunction() {
$
(
'.folder'
).
css
(
'font-weight'
,
'normal'
);
$
(
'.folder'
).
css
(
'text-decoration'
,
'none'
);
$
(
'#all'
).
css
(
'font-weight'
,
'bold'
);
$
(
'#all'
).
css
(
'text-decoration'
,
'underline'
);
var
recordFrom
=
0
;
var
recordTo
=
0
;
...
...
@@ -498,7 +506,10 @@ function groupSelectFunction() {
$
(
'.folder'
).
css
(
'font-weight'
,
'normal'
);
$
(
'.folder'
).
css
(
'text-decoration'
,
'none'
);
var
firstNode
=
$
(
'#list_1'
).
find
(
'a'
)[
0
];
$
(
'#list_1'
).
find
(
firstNode
).
css
(
'text-decoration'
,
'underline'
);
$
(
'#list_1'
).
find
(
firstNode
).
css
(
'font-weight'
,
'bold'
);
var
recordFrom
=
0
;
var
recordTo
=
0
;
...
...
@@ -564,12 +575,16 @@ function getDataJsonFileGenre(){
}
});
var
tree1
=
new
TreeView
();
tree1
.
CategoryTagName
=
"a"
;
//tree1.TotalCount = totalCount;
if
(
genre_totalcontent
!=
-
1
)
{
tree1
.
TotalCount
=
genre_totalcontent
;
}
tree1
.
Show
(
"list_0"
,
arrData
,
"AddGenre_Callback"
);
$
(
"#list_0"
).
treeview
();
$
(
'#all'
).
css
(
'font-weight'
,
'bold'
);
$
(
'#all'
).
css
(
'text-decoration'
,
'underline'
);
});
}
...
...
@@ -628,7 +643,7 @@ function AddGenre_Callback(selectedNode) {
$
(
'#'
+
selectedNode
.
Id
).
css
(
'font-weight'
,
'bold'
);
$
(
'#'
+
selectedNode
.
Id
).
css
(
'text-decoration'
,
'underline'
);
}
}
}
var
node
=
new
TreeNode
();
var
recordFrom
=
0
;
...
...
@@ -701,15 +716,20 @@ function getDataJsonFileGroup(){
}
});
var
tree2
=
new
TreeView
();
tree2
.
CategoryTagName
=
"a"
;
//tree1.TotalCount = totalCount;
if
(
group_totalcontent
!=
-
1
)
{
tree2
.
TotalCount
=
group_totalcontent
;
}
tree2
.
Show
(
"list_1"
,
arrData
,
"AddGroup_Callback"
);
$
(
"#list_1"
).
treeview
();
$
(
"#list_1"
).
treeview
();
var
firstNode
=
$
(
'#list_1'
).
find
(
'a'
)[
0
];
$
(
'#list_1'
).
find
(
firstNode
).
css
(
'text-decoration'
,
'underline'
);
$
(
'#list_1'
).
find
(
firstNode
).
css
(
'font-weight'
,
'bold'
);
// Expand nodes
for
(
var
nIndex
=
0
;
nIndex
<
tree2
.
ExpandNodes
.
length
;
nIndex
++
)
{
for
(
var
nIndex
=
0
;
nIndex
<
tree2
.
ExpandNodes
.
length
;
nIndex
++
)
{
if
(
$
(
"#"
+
tree2
.
ExpandNodes
[
nIndex
]).
parent
())
{
var
objParent
=
$
(
"#"
+
tree2
.
ExpandNodes
[
nIndex
]).
parent
();
var
objChild
=
objParent
.
children
()[
0
];
...
...
@@ -726,7 +746,7 @@ function getDataJsonFileGroup(){
}
}
}
}
});
}
...
...
@@ -785,7 +805,7 @@ function AddGroup_Callback(selectedNode) {
$
(
'#'
+
selectedNode
.
Id
).
css
(
'font-weight'
,
'bold'
);
$
(
'#'
+
selectedNode
.
Id
).
css
(
'text-decoration'
,
'underline'
);
}
}
}
var
node
=
new
TreeNode
();
var
recordFrom
=
0
;
...
...
@@ -1801,6 +1821,9 @@ function setMetaVersionData(conId){
//handle display sort direction
function
handleSortDisp
(){
$
(
'#control-sort-title'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-titlekana'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-releasedate'
).
removeClass
(
'active_tops'
);
var
typeSort
;
var
orderSort
;
...
...
@@ -1816,6 +1839,10 @@ function handleSortDisp(){
orderSort
=
ClientData
.
searchCond_sortOrder
();
if
(
typeSort
==
1
){
$
(
'#control-sort-title'
).
addClass
(
'active_tops'
);
$
(
'#control-sort-titlekana'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-releasedate'
).
removeClass
(
'active_tops'
);
if
(
orderSort
==
Consts
.
ConstOrderSetting_Asc
){
$
(
'#title-sorttype'
).
html
(
''
);
$
(
'#title-sorttype'
).
html
(
'▲'
);
...
...
@@ -1832,6 +1859,10 @@ function handleSortDisp(){
}
}
else
if
(
typeSort
==
2
){
$
(
'#control-sort-title'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-titlekana'
).
addClass
(
'active_tops'
);
$
(
'#control-sort-releasedate'
).
removeClass
(
'active_tops'
);
if
(
orderSort
==
Consts
.
ConstOrderSetting_Asc
){
$
(
'#title-sorttype'
).
html
(
''
);
$
(
'#titlekana-sorttype'
).
html
(
''
);
...
...
@@ -1848,6 +1879,10 @@ function handleSortDisp(){
}
}
else
{
$
(
'#control-sort-title'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-titlekana'
).
removeClass
(
'active_tops'
);
$
(
'#control-sort-releasedate'
).
addClass
(
'active_tops'
);
if
(
orderSort
==
Consts
.
ConstOrderSetting_Asc
){
$
(
'#title-sorttype'
).
html
(
''
);
$
(
'#titlekana-sorttype'
).
html
(
''
);
...
...
abvw/js/login.js
View file @
bcb0622d
...
...
@@ -24,7 +24,8 @@ var force_pw_change_periodically;
var
user_data_backup
;
var
marking
;
var
force_login_periodically
;
var
login_errorMessage
=
""
;
//Load login Info
function
loadLoginInfo
()
{
...
...
@@ -92,18 +93,23 @@ function checkValidation() {
var
msgError
=
$
(
'#main-error-message'
);
if
(
!
ValidationUtil
.
CheckRequiredForText
(
accountPath
))
{
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgLoginEmpty'
));
msgError
.
attr
(
'lang'
,
'msgLoginEmpty'
);
msgError
.
show
();
return
false
;
}
else
if
(
!
ValidationUtil
.
CheckRequiredForText
(
loginId
))
{
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgLoginEmpty'
));
msgError
.
attr
(
'lang'
,
'msgLoginEmpty'
);
msgError
.
show
();
return
false
;
}
else
if
(
!
ValidationUtil
.
CheckRequiredForText
(
password
))
{
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgLoginEmpty'
));
msgError
.
attr
(
'lang'
,
'msgLoginEmpty'
);
msgError
.
show
();
return
false
;
}
...
...
@@ -120,7 +126,9 @@ function checkDialogValidation(){
var
msgError
=
$
(
'#dialog-error-message'
);
if
(
!
ValidationUtil
.
CheckRequiredForText
(
currentPass
))
{
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgPwdEmpty'
));
msgError
.
attr
(
'lang'
,
'msgPwdEmpty'
);
msgError
.
show
();
/* show error messages */
...
...
@@ -134,7 +142,9 @@ function checkDialogValidation(){
return
false
;
}
else
if
(
!
ValidationUtil
.
CheckRequiredForText
(
newPass
))
{
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgPwdEmpty'
));
msgError
.
attr
(
'lang'
,
'msgPwdEmpty'
);
msgError
.
show
();
/* show error messages */
//$().toastmessage({ position: 'middle-center' });
...
...
@@ -161,7 +171,9 @@ function checkDialogValidation(){
else
{
if
(
newPass
!=
confirmPass
){
login_errorMessage
=
""
;
msgError
.
html
(
i18nText
(
'msgPwdNotMatch'
));
msgError
.
attr
(
'lang'
,
'msgPwdNotMatch'
);
msgError
.
show
();
/* show error messages */
// $().toastmessage({ position: 'middle-center' });
...
...
@@ -304,6 +316,7 @@ function processLogin() {
}
}
else
{
login_errorMessage
=
data
.
errorMessage
;
$
(
'#main-error-message'
).
html
(
format
(
i18nText
(
'msgLoginErrWrong'
),
data
.
errorMessage
).
toString
());
$
(
'#main-error-message'
).
show
();
...
...
@@ -321,6 +334,7 @@ function processLogin() {
}
},
function
(
xhr
,
statusText
,
errorThrown
)
{
login_errorMessage
=
JSON
.
parse
(
xhr
.
responseText
).
errorMessage
;
//$('#main-error-message').html(format(i18nText('msgLoginErrWrong'), formatErrorCode(a.status)).toString());
if
(
xhr
.
responseText
&&
xhr
.
status
!=
0
)
{
$
(
'#main-error-message'
).
html
(
format
(
i18nText
(
'msgLoginErrWrong'
),
JSON
.
parse
(
xhr
.
responseText
).
errorMessage
).
toString
());
...
...
@@ -372,21 +386,30 @@ function changePasswordProcess(){
function
changeLanguageJa
(){
changeLanguage
(
Consts
.
ConstLanguage_Ja
);
document
.
title
=
i18nText
(
'dspLogin'
)
+
' | '
+
i18nText
(
'sysAppTitle'
);
//ClientData.userInfo_language(Consts.ConstLanguage_Ja);
//ClientData.userInfo_language(Consts.ConstLanguage_Ja);
if
(
login_errorMessage
!=
""
){
$
(
'#main-error-message'
).
html
(
format
(
i18nText
(
'msgLoginErrWrong'
),
login_errorMessage
).
toString
());
}
}
//Change Language Korean
function
changeLanguageKo
(){
changeLanguage
(
Consts
.
ConstLanguage_Ko
);
document
.
title
=
i18nText
(
'dspLogin'
)
+
' | '
+
i18nText
(
'sysAppTitle'
);
//ClientData.userInfo_language(Consts.ConstLanguage_Ko);
//ClientData.userInfo_language(Consts.ConstLanguage_Ko);
if
(
login_errorMessage
!=
""
){
$
(
'#main-error-message'
).
html
(
format
(
i18nText
(
'msgLoginErrWrong'
),
login_errorMessage
).
toString
());
}
}
//Change Language English
function
changeLanguageEn
(){
changeLanguage
(
Consts
.
ConstLanguage_En
);
document
.
title
=
i18nText
(
'dspLogin'
)
+
' | '
+
i18nText
(
'sysAppTitle'
);
//ClientData.userInfo_language(Consts.ConstLanguage_En);
//ClientData.userInfo_language(Consts.ConstLanguage_En);
if
(
login_errorMessage
!=
""
){
$
(
'#main-error-message'
).
html
(
format
(
i18nText
(
'msgLoginErrWrong'
),
login_errorMessage
).
toString
());
}
}
//Login click function
...
...
abvw/js/settings.js
View file @
bcb0622d
...
...
@@ -354,10 +354,19 @@ function dspSave_Click(e) {
}
// マーキング(コンテンツを開いた時に表示する)
if
(
$
(
"#chkOpt003"
).
attr
(
'checked'
)
==
'checked'
)
{
ClientData
.
userOpt_makingDsp
(
1
);
ClientData
.
userOpt_makingDsp
(
1
);
}
else
{
ClientData
.
userOpt_makingDsp
(
0
);
ClientData
.
userOpt_makingDsp
(
0
);
}
// Show/not show alert when press F5.close tab.broswer.
if
(
$
(
"#chkOpt005"
).
attr
(
'checked'
)
==
'checked'
)
{
ClientData
.
userOpt_closeOrRefreshAlert
(
1
);
ToogleLogoutNortice
();
}
else
{
ClientData
.
userOpt_closeOrRefreshAlert
(
0
);
ToogleLogoutNortice
();
}
// 毎回ログアウトの時、バックアップするかどうかは必ず確認する
if
(
$
(
"#chkOptBkCfm"
).
attr
(
'checked'
)
==
'checked'
)
{
...
...
@@ -430,6 +439,8 @@ function dspOptReset_Click(e) {
$
(
"#chkOpt002"
).
attr
(
'checked'
,
'checked'
);
// マーキング(コンテンツを開いた時に表示する)
$
(
"#chkOpt003"
).
attr
(
'checked'
,
'checked'
);
// Show alert when press F5.close tab.broswer
$
(
"#chkOpt005"
).
attr
(
'checked'
,
'checked'
);
// 毎回ログアウトの時、バックアップするかどうかは必ず確認する
$
(
"#chkOptBkCfm"
).
attr
(
'checked'
,
'checked'
);
}
...
...
@@ -737,7 +748,13 @@ function InitScreen() {
$
(
"#chkOpt003"
).
attr
(
'checked'
,
'checked'
);
}
// Show alert when press F5.close tab.broswer
if
(
ClientData
.
userOpt_closeOrRefreshAlert
()
==
0
)
{
$
(
"#chkOpt005"
).
removeAttr
(
'checked'
);
}
else
{
$
(
"#chkOpt005"
).
attr
(
'checked'
,
'checked'
);
}
// 毎回ログアウトの時、バックアップするかどうかは必ず確認する
if
(
ClientData
.
userOpt_bkConfirmFlg
()
==
0
)
{
$
(
"#chkOptBkCfm"
).
removeAttr
(
'checked'
);
...
...
abvw/settings.html
View file @
bcb0622d
...
...
@@ -104,6 +104,7 @@
</li>
<li><label><input
type=
checkbox
name=
"repeat"
value=
"repeat"
class=
"chkbx"
id=
"chkOpt002"
checked=
"checked"
/><label
for=
"chk1"
id=
"txtOpt002"
lang=
"txtOpt002"
class=
"lang"
>
動画、音楽繰り返し
</label></label></li>
<li><label><input
type=
checkbox
name=
"marking"
value=
"marking"
class=
"chkbx"
id=
"chkOpt003"
checked=
"checked"
/><label
id=
"lblOpt003"
for=
"chkOpt003"
lang=
"txtOpt003"
class=
"lang"
>
マーキング(コンテンツを開いた時に表示する)
</label></label><span
class=
"notice lang"
lang=
"txtOpt004"
>
※コンテンツを開いた時に表示する
</span></li>
<li><label><input
type=
checkbox
name=
"confirmClose"
value=
"confirmClose"
class=
"chkbx"
id=
"chkOpt005"
checked=
"checked"
/><label
for=
"chk1"
id=
"txtOpt005"
lang=
"txtOpt005"
class=
"lang"
>
タブ・ブラウザ終了・F5時のアラートが表示する
</label></label></li>
</ul>
<h3
id=
"txtBkResCap"
lang=
"txtBkResCap"
class=
"lang"
>
サーバにバックアップ/リストア
</h3>
<p
class=
"logout_backup"
><label><input
type=
checkbox
name=
"backup"
value=
"backup"
id=
"chkOptBkCfm"
checked=
"checked"
><label
id=
"txtOptBkCfm"
for=
"chkOptBkCfm"
lang=
"txtOptBkCfm"
class=
"lang"
>
毎回ログアウトの時、バックアップするかどうかは必ず確認する
</label></label></p>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment