diff --git a/examples/classic-slides/index.html b/examples/classic-slides/index.html
index 3de0c92..2534ecf 100644
--- a/examples/classic-slides/index.html
+++ b/examples/classic-slides/index.html
@@ -101,7 +101,7 @@
powerpoint slide show. The "slide" class is entirely optional and indeed you wouldn't use it for
your cooler impress.js presentations.
-->
-
+
Example Presentation:
Classic Slides
Henrik Ingo
@@ -114,7 +114,7 @@
-
-
+
Bullet points
- A slide with bullet points. This is the first point.
diff --git a/examples/index.html b/examples/index.html
index 1e5924b..945c7f1 100644
--- a/examples/index.html
+++ b/examples/index.html
@@ -6,6 +6,7 @@
- 2D-navigation
- 3D-rotations
+ - 692
- classic-slides
- cube
- markdown
diff --git a/js/impress.js b/js/impress.js
index b36a750..bb99522 100644
--- a/js/impress.js
+++ b/js/impress.js
@@ -3566,7 +3566,7 @@
}
};
- var computeRelativePositions = function( el, prev, root ) {
+ var computeRelativePositions = function( el, prev ) {
var data = el.dataset;
if ( !prev ) {
@@ -3577,14 +3577,14 @@
if ( data.relTo ) {
- var ref = root.getElementById( data.relTo );
+ var ref = document.getElementById( data.relTo );
if ( ref ) {
// Test, if it is a previous step that already has some assigned position data
if ( el.compareDocumentPosition( ref ) & Node.DOCUMENT_POSITION_PRECEDING ) {
- prev.x = ref.getAttribute( "data-x" );
- prev.y = ref.getAttribute( "data-y" );
- prev.z = ref.getAttribute( "data-z" );
+ prev.x = toNumber( ref.getAttribute( "data-x" ) );
+ prev.y = toNumber( ref.getAttribute( "data-y" ) );
+ prev.z = toNumber( ref.getAttribute( "data-z" ) );
prev.relative = {};
} else {
window.console.error(
@@ -3650,7 +3650,7 @@
y: el.getAttribute( "data-y" ),
z: el.getAttribute( "data-z" )
} );
- var step = computeRelativePositions( el, prev, root );
+ var step = computeRelativePositions( el, prev );
// Apply relative position (if non-zero)
el.setAttribute( "data-x", step.x );
diff --git a/src/plugins/rel/rel.js b/src/plugins/rel/rel.js
index cd9b3e8..b3f1b45 100644
--- a/src/plugins/rel/rel.js
+++ b/src/plugins/rel/rel.js
@@ -77,7 +77,7 @@
}
};
- var computeRelativePositions = function( el, prev, root ) {
+ var computeRelativePositions = function( el, prev ) {
var data = el.dataset;
if ( !prev ) {
@@ -88,14 +88,14 @@
if ( data.relTo ) {
- var ref = root.getElementById( data.relTo );
+ var ref = document.getElementById( data.relTo );
if ( ref ) {
// Test, if it is a previous step that already has some assigned position data
if ( el.compareDocumentPosition( ref ) & Node.DOCUMENT_POSITION_PRECEDING ) {
- prev.x = ref.getAttribute( "data-x" );
- prev.y = ref.getAttribute( "data-y" );
- prev.z = ref.getAttribute( "data-z" );
+ prev.x = toNumber( ref.getAttribute( "data-x" ) );
+ prev.y = toNumber( ref.getAttribute( "data-y" ) );
+ prev.z = toNumber( ref.getAttribute( "data-z" ) );
prev.relative = {};
} else {
window.console.error(
@@ -161,7 +161,7 @@
y: el.getAttribute( "data-y" ),
z: el.getAttribute( "data-z" )
} );
- var step = computeRelativePositions( el, prev, root );
+ var step = computeRelativePositions( el, prev );
// Apply relative position (if non-zero)
el.setAttribute( "data-x", step.x );