mirror of
https://github.com/flynx/PortableMag.git
synced 2025-11-01 12:30:19 +00:00
added transform switching...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
0daed0a12d
commit
610f80315c
12
index.html
12
index.html
@ -852,13 +852,21 @@ $(document).ready(function(){
|
|||||||
<button id="DRAG_FULL_PAGE" onclick="toggleSetting(this)"></button>
|
<button id="DRAG_FULL_PAGE" onclick="toggleSetting(this)"></button>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<!--tr>
|
||||||
<td>
|
<td>
|
||||||
Toggle viewer animation (affects transition to and from full page view):
|
Toggle viewer animation (affects transition to and from full page view):
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<button id="viewer_transition_state" onclick="toggleViewerAnimation()"></button>
|
<button id="viewer_transition_state" onclick="toggleViewerAnimation()"></button>
|
||||||
</td>
|
</td>
|
||||||
|
</tr-->
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Use transform to drag:
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<button id="USE_TRANSFORM" onclick="toggleSetting(this); setCurrentPage()"></button>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
@ -975,6 +983,7 @@ $(document).ready(function(){
|
|||||||
USE_REAL_PAGE_SIZES = $('#USE_REAL_PAGE_SIZES').text() == 'true' ? true : false
|
USE_REAL_PAGE_SIZES = $('#USE_REAL_PAGE_SIZES').text() == 'true' ? true : false
|
||||||
UPDATE_HASH_URL_POSITION = $('#UPDATE_HASH_URL_POSITION').text() == 'true' ? true : false
|
UPDATE_HASH_URL_POSITION = $('#UPDATE_HASH_URL_POSITION').text() == 'true' ? true : false
|
||||||
FULL_HISTORY_ENABLED = $('#FULL_HISTORY_ENABLED').text() == 'true' ? true : false
|
FULL_HISTORY_ENABLED = $('#FULL_HISTORY_ENABLED').text() == 'true' ? true : false
|
||||||
|
USE_TRANSFORM = $('#USE_TRANSFORM').text() == 'true' ? true : false
|
||||||
|
|
||||||
}
|
}
|
||||||
function loadSettings(){
|
function loadSettings(){
|
||||||
@ -986,6 +995,7 @@ $(document).ready(function(){
|
|||||||
$('#USE_REAL_PAGE_SIZES').text(USE_REAL_PAGE_SIZES)
|
$('#USE_REAL_PAGE_SIZES').text(USE_REAL_PAGE_SIZES)
|
||||||
$('#UPDATE_HASH_URL_POSITION').text(UPDATE_HASH_URL_POSITION)
|
$('#UPDATE_HASH_URL_POSITION').text(UPDATE_HASH_URL_POSITION)
|
||||||
$('#FULL_HISTORY_ENABLED').text(FULL_HISTORY_ENABLED)
|
$('#FULL_HISTORY_ENABLED').text(FULL_HISTORY_ENABLED)
|
||||||
|
$('#USE_TRANSFORM').text(USE_TRANSFORM)
|
||||||
$('#theme_toggler').text(toggleThemes('?'))
|
$('#theme_toggler').text(toggleThemes('?'))
|
||||||
$('#theme_shadow_toggler').text(toggleShadows('?'))
|
$('#theme_shadow_toggler').text(toggleShadows('?'))
|
||||||
|
|
||||||
|
|||||||
13
magazine.js
13
magazine.js
@ -223,12 +223,23 @@ function shiftMagazineTo(offset){
|
|||||||
'-moz-transform' : transform,
|
'-moz-transform' : transform,
|
||||||
'-o-transform' : transform,
|
'-o-transform' : transform,
|
||||||
'transform' : transform,
|
'transform' : transform,
|
||||||
|
|
||||||
|
// XXX can we avoid this here??
|
||||||
|
left: 0,
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
|
var transform = 'translate(0px, 0px) translateZ(0px)'
|
||||||
mag.css({
|
mag.css({
|
||||||
// NOTE: this will be wrong during a transition, that's why we
|
// NOTE: this will be wrong during a transition, that's why we
|
||||||
// can pass the pre-calculated offset as an argument...
|
// can pass the pre-calculated offset as an argument...
|
||||||
left: offset
|
left: offset,
|
||||||
|
|
||||||
|
// XXX can we avoid this here??
|
||||||
|
'-ms-transform' : transform,
|
||||||
|
'-webkit-transform' : transform,
|
||||||
|
'-moz-transform' : transform,
|
||||||
|
'-o-transform' : transform,
|
||||||
|
'transform' : transform,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user