[Javascript][Fixed-layout] - Is it an event fired when each page of the book is completely loaded ?

Hi,
everything is in the title.
I want to set a page at the beginning of the book where the reader will have to wait until the book is fully loaded in iBooks.
(A kind of onLoad event but for the whole book)
This will be usefull to prevent lags when reading the fixed-layout epub.
Thank you.

Hi Oliboy50,
I believe the iBooks app handles this for you.
Are you able to use the DOMContentLoaded event listener like this to solve your problem? There is a function in ibooks.js to initialise all js, you could potentially add your functionality to that once iBooks as done the init. Have a look around line 200.
window.addEventListener("DOMContentLoaded", function() {
    // Your code here
}, false);
Hope that hepls.
Seb

Similar Messages

  • Event Fired when a mxml component is shown on screen

    hello,
    I have following application structure nested up to 2/3 level.
    Application
         linkbar connected to viewstack
         viewstack
              NavigatorContent
                   mxml Component
              NavigatorContent
                   mxml Component
    mxml componet in turn has similar structure
    componet
         linkbar connected to viewstack
         viewstack
              NavigatorContent
                   mxml Component
              NavigatorContent
                   mxml Component
    and end component is form which is shown and actions performed
    I want to execute specific code when the form is first time shown
    which will collect data from server and will show for further actions.
    User will edit/delete/update data with various button clicks.
    I tried activate event on end component but it seems that it wont get
    fired at all. End components are enclosed in BorderContainer or Group.
    To test activate event I have used Alert.show only but popup is not shown
    when I select link button on penutimate linkbar.
    If I am doing something wrong please let me know as well please
    guide me which event shall I use so that whenever linkbutton is
    pressed on linkbar it will fire that event. In that event I can check
    whether it has been called earlier by checking some variable which
    will be null in creation complete and set in event fired when linkbutton is pressed.
    Thanks and regards
    Raja

    I think 'creationComplete' is the closest event to what you are looking for.

  • E book" it tells me that the bI have prepared a photobook, made a pdf and when I press "buy the book is missing photos on one ore more pages. The book does not miss any photos or text, all layouts are ok, the background color is ok. Can anybody help me?

    I have prepared a photo book, made a pdf and when I press "buy thhe book" it tells me that the book is missing photos on one ore more pages. The book does not miss any photos or text, all layouts are ok, the background color is ok. Can anybody help me?

    You are missing one or more photos - youprobably have a page background that requires a photo which is behind a page with photos on it - all pages must either have a photo or be a color - if you have a gray background it requires a photo - look through the book carefully and be sure to look at the background on any full page photos - you will find one or more missing photos
    LN

  • I have LR 5.  When I'm in the book module and select the option to "Send Book to Blurb" i get an error message saying "The file does not have a program associated with it...."  How do I fix this?

    I have LR 5.  When I'm in the book module and select the option to "Send Book to Blurb" i get an error message saying "The file does not have a program associated with it for performing this action.  Please install a program, or if one is already installed, create an association in the Default Programs control panel."
    How do I fix this?

    Try the following user tip:
    "There is a problem with this Windows Installer package ..." error messages when installing iTunes for Windows

  • REMOVED_FROM_STAGE event firing when it shouldn't...

    Hello everyone,
    Wondering if someone has seen this before. I have an application that has a few navigation points on the main timeline. The document class stops the movie at the first frame, and the "home" movieclip's class has Event.ADDED_TO_STAGE and Event.REMOVED_FROM_STAGE listeners on it. Funny thing is, it is calling the ADDED function as normal, then firing the REMOVED function immediately after. However, when I run it, it doesn't actually remove the movieclip from the stage. It is still there. When I navigate to a different section ("remote" or "assist") and navigate back to "home", it doesn't fire a second time, everything works properly after the first time.
    So I guess my question is, what would fire the REMOVED_FROM_STAGE event without actually removing the object from the stage? And why would it only happen once?
    Thanks for looking!
    -Nick
    Here is some code as well as a screen shot of my main timeline:
    package src.modules {
        import flash.display.MovieClip;
        import flash.events.Event;
        import flash.events.MouseEvent;
        import src.utils.greensock.TweenLite;
        import src.utils.greensock.easing.*;
        public class ModHome extends MovieClip {
            private static const DISTANCE:int = 700;
            private static const TWEEN_DURATION:Number = 1.0;
            private var _currentPage:int = 1;
            private var _isDone:Boolean = true;
            public function ModHome() {
                super();
    //            trace("home initialized");
                addEventListener(Event.ADDED_TO_STAGE, onAddedToStage, false, 0, true);
            private function onAddedToStage(evt:Event):void {
                trace("home added to stage");
                removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
                addEventListener(Event.REMOVED_FROM_STAGE, onRemovedFromStage, false, 0, true);
                // BUTTONS
                pageLeft_btn.addEventListener(MouseEvent.CLICK, onMouseClick, false, 0, true);
                pageRight_btn.addEventListener(MouseEvent.CLICK, onMouseClick, false, 0, true);
            private function onRemovedFromStage(evt:Event):void {
                removeEventListener(Event.REMOVED_FROM_STAGE, onRemovedFromStage);
                // BUTTONS
                pageLeft_btn.removeEventListener(MouseEvent.CLICK, onMouseClick);
                pageRight_btn.removeEventListener(MouseEvent.CLICK, onMouseClick);
    //            trace("home removed from stage");
            private function onMouseClick(evt:MouseEvent):void {
                if(_isDone) {
                    switch (evt.target.name) {
                        case "pageLeft_btn" :
                            movePages("left");
                            break;
                        case "pageRight_btn" :
                            movePages("right");
                            break;
                        default :
    //                        trace("home -- nothing");
                            break;
            // SCROLLING WINDOW
            private function movePages(thedirection:String):void {
                _isDone = false;
                var x1:int;
                switch (thedirection) {
                    case "right" :
                        if (_currentPage > 1) {
                            _currentPage = _currentPage - 1;
                            x1 = pages_mc.x + DISTANCE;
                            TweenLite.to(pages_mc, TWEEN_DURATION, {x:x1, ease:Quint.easeInOut, onComplete:onTweenComplete});
                        } else {
                            _isDone = true;
                        break;
                    case "left" :
                        if (_currentPage < 3) {
                            _currentPage = _currentPage + 1;
                            x1 = pages_mc.x - DISTANCE;
                            TweenLite.to(pages_mc, TWEEN_DURATION, {x:x1, ease:Quint.easeInOut, onComplete:onTweenComplete});
                        } else {
                            _isDone = true;
                        break;                   
            private function onTweenComplete():void {
                _isDone = true;
                pageMarker_mc.gotoAndStop(_currentPage);
    //            trace("complete");

    No reason in particular, when I created the class, FlashBuilder put it in there (I'm using Flash Pro CS5 + Flash Builder 4). I read that it calls it by default when the class is constructed, so having it in or out didn't really matter. I did comment it out with no luck, but I ended up shifting around the timeline quite a bit today and the problem has gone away. It seemed to only do it when it was in the first frame.
    Thanks for your help, I'm going to investigate it further when I have time just for reference, I'll post anything I find here.
    -Nick

  • Indesign CC 2014 Fixed-Layout Epub exported great for iBooks.  Can I do the same for Kindle?

    I have read a lot about being able to edit the Epub code in a Fixed-Layout Indesign CC exported Epub.  This Epub works great in IBooks. What I read said I could clean up the
    code so it works for Kindle.  But I can't figure out what code needs to be cleaned out.  How can I export it correctly or clean it up?
    Hope someone here knows,
    Thanks for the help in advance,
    Janis

    Monica,
    Thanks for your response.
    I tried again as you suggested.
    I exported a Fixed Layout ePub (exported size ~29mb) and tried to load it on an Mac, iPad and iPhone 5s. The results are inconsistent. On the Mac, I received a message that the file was corrupt. On the iPad, the file did eventually load (the quality of the output is another discussion - sneak preview, it's not as good as Circular Flo. Lots of weird stuff). On the iPhone 5s, iBooks is still spinning and has been for about 10 minutes.
    Michael

  • Event firing when XML data is imported via Acrobat

    When a user in Acrobat imports xml data into a form, what event gets fired? I have a couple of actions that occur on change, but when I import xml into the form (to fill in values, etc), this event doesn't fire. Is it on initialize?

    Yea, I dug a little deeper and ended up using the initialize event. What I did was on the initialize event I execute the exit script. So it's the same as the user physically putting the value in. Plus, I dont have to have the same code in two places.
    In the initialize event code:
    myThingie.execEvent("exit");
    Pretty cool little function if you find it useful. Thanks for the reply.

  • MediaPlayback - event fired when file not found?

    I want to have a playlist containing mp3 from multiple sites.
    I would like to use the MediaPlayback component to play these. If
    we try to play an mp3 that is not currently available we'd simply
    like to skip to the next mp3. I don't see any event or anyway to
    detect if a file was not found.
    We'll be using the "complete" event to know when to start the
    next mp3. Unfortunately this event it not fired in the scenario
    where the file is not available.
    Any suggestions (other than using the Sound object directly)?
    Thanks in advance.

    Hi,
           Refer these links for Java i\o operations.
    http://www.java2s.com/Code/Java/File-Input-Output/CatalogFile-Input-Output.htm
    http://download.oracle.com/javase/tutorial/essential/io/check.html
    http://www.roseindia.net/java/example/java/io/
    For java mapping help, pls search in sdn, you will find lots of helpful blogs
    Regards

  • To cure the March 2013 monthly Calendar problem I amended my All- Day events for April 1 to timed events on my iPad.  Now the Calendar does not load at all on the iPad, but still OK on iPhone 5.  Any suggestions please?

    In order to cure the problem on my iPad of the month of March 2013 only causing the Calendar to close, I amended all "All Day" events on April 1 to timed events.  Now my Calendar will not open, although my Calendar on an iPad 2 and on iPhones 5 &amp; 4 work perfectly.  I have tried turning iPad off/on, but no effect.  Any ideas please?

    I'm having the same issue with my 3rd gen iPad too. I always viewed my calendar in month view. It won't even open since it's stuck on month view.
    I've quit the app (properly closing via taskbar) and re-opened - crashes immediatly.
    Quit the app and rebooted (via holding home/power buttons until restart) and opened - still crashes immediatly.
    Anyone know how I'm able to get access to the app so I can change all day events to timed events in April. Is it just April 1st or all of April? I haven't even opened my iPhones iCal yet to see if it's having the same issue.
    Also, not sure if this will work but iCal on my mac wireless syncs my calendar events. I'm wondering if I change April 1st all day events to timed events whether it'll sync and fix the issue of crashing?

  • How can I fix my display that had vertical lines when I open/close the lid?

    Just a few minutes ago, as I was adjusting the Macbook's lid, I got a huge vertical line showing on my display. The line goes away after I fiddled with the lid a little. Now, every time I open/close the lid, the lines sometimes pop in and out, always in the same area.
    I'm scared the wires connecting to the Macbook's display is loose or something. What can I fix it?
    Here's a picture of how it looks like: http://img341.imageshack.us/img341/7683/picture4gj.png

    Sounds like the LVDS cable might have come loose somewhere or is faulty, would not say it's the LCD just yet. If it's under warranty just take it to any apple store or local service provider. If it's out of warranty I would not suggest taking to an Apple Store because they will just quote you the whole display, but an Apple Service Provider might be able or wiling to attempt to just repair the faulty part in the display(just know your model display does not come apart easily) http://support.apple.com/kb/HT1434 , good luck

  • How can I fix my Safary navigator (and other aplications) when I'm receiving the arab text code?

    Well, I'm receving constantely the arab text code by mail or on Twitter app (by IOS)  and all aplications crashes.
    Sometimes I'm surfing and the god dammit code is in the homepage source and crash the aplications. The same thing at IOS.
    I'm without ideas about guys.
    Any help?

    Mail unexpectedly quits when viewing certain messages

  • Fixed Layout ePub - please help me embed video and/or use Folio overlay with web content

    Hi
    I have an In Design file used to create a print book (11"x11") and have decided to use CC 2014 to create a fixed-layout ePub 3 for a digital version.  I converted the book over with minor issues of having to change the font and it looks beautiful.
    I would like to add videos at the end of the book to take advantage of the flexibility of the digital format.  I create a year-end slideshow of my photos and host them on Vimeo.
    I have tried the following:
    Using the Vimeo standard embed code in an HTML element
    Using the old flash Vimeo embed code and converting to HTML - worked great on iBooks on Mac but not on iPhone/iPad as flash-based
    Hosting and linking to videos on my own web server and using the Media - insert video link to the mp4 file
    Hosting and linking to videos on my old photo server at smugmug.com
    I can embed the actual videos but, at their smallest size they increase the file size of the ePub from 78MB to 400MB...
    I then thought I would use a Folio Overlay - Web Content.
    The idea is to use this blank page on my website which would look for all intents and purposes like another white page in the book - 2012 Slideshow - Oren Photography
    The overlay works in Folio Preview but not when exported as an ePub
    Is this a limitation of the ePub format?
    Any help/advice/suggestions on fixing this are greatly appreciated.
    E

    Thanks again Steve and Bill
    My interest in embedding videos was largely to minimize the final file size and amount of space used on each person's device.  I ended up following your advice about using Adobe Media Encoder to minimize the size of each slideshow but it still increased the final ePub from 65 MB to over 200 MB.  And that was with video quality that was far inferior from what I could offer through an embed or, my final solution, a link out to my website.
    I happen to be of the same thought as Bill that most people are now connected to the internet and would favor a smaller file with access to online content over a very large file.  I would have liked to embed the videos and allow 720p quality inside the ePub over the link I ended up settling for.
    E

  • Use of cookies in fixed-layout EPUBs

    I am creating a fixed-layout picture ebook in EPUB2 format to be published on the iBookstore.
    In order to start some CSS3 animations at the same time on both pages of a page spread, I'd like to use a mechanism to synchronize the start time for the animations. This is because I noted that, in the iBook reader running on my iPad2, the left and right pages of a spread get loaded at different times and usually the right page is loaded approximately 1s later than the left page, though the delay is extremely variable.
    I am thinking about using some javascript to set a cookie in order to check whether both pages in a spread are loaded and consequently start the animations. This is based on the assumption that both pages of a spread use a webview built upon the same common Safari rendering engine which uses a single set of cookies.
    My questions are:
    Is it allowed to use cookies in an EPUB to be published on the Apple iBookstore? On page 29 of the iBookstore Asset Guide 5.0 it is specified that "Books must not rely on external resources", but are cookies to be considered "external resources"?
    If cookies are not allowed, is there any other way to synchronize the two pages of a page spread on the iBook reader?

    Hi Steve, I am a regular subscriber to Creative Cloud and have updated all apps.  My version of Adobe InDesign does show 2014.1 under About InDesign.
    Believe it or not, one of the more helpful videos out in Adobe TV land showed interactive under the Object menu:
    See 5:30 on this page: https://helpx.adobe.com/indesign/how-to/interactivity-fixed-layout-epub.html?set=indesign- -key-techniques--epub-fixed-layout  I finally found the answer here at Adobe forums (monica).   Now I have it installed in the panel on the right.
    I'm on an iMac and use all Apple products.   I've tossed Windows to the wind. 
    Thank you so much for your support. 
    Mary

  • In a fixed-layout epub is there a way to turn off the faux spine effect for just one pair of pages?

    I'm formatting a graphic novel as a fixed-layout epub.  Because the pages are generated in Manga Studio with an intended print target, it by far makes the most sense to just use a single, large image for each page.  I'm coding the .opf, .xhtml, and .css files by hand, and I more or less understand everything I'm doing.
    Because the pages are often full bleed, I actually want the faux book chrome afforded by having <meta property="ibooks:binding">true</meta>.  The shadow effect in the gutter gives a nice deliniation between the pages without me having to do anything additional with the formatting.
    However... a handful of pages in the book are two-page spreads.  These look good enough with the shadow spine in the middle, but they would obviously look better without it.  What I'd like to do is identify these particular page pairs as two-page spreads and turn the binding chrome off for just that page pair.  I could of course "fake it" by adding a shadow to the pages themselves (except the spreads) and turning off the binding chrome on the entire book, but it'd be a lot easier to be able to do it in software.
    Apple's formatting guide mentioned nothing of the sort, and searching for a while hasn't turned up anything (not even anyone asking the same question so far as I can tell).  I'm guessing this isn't possible, but it never hurts to ask.  Anybody know of a way to do this?

    Just found this... Sorry to waste the post...
    http://reviews.cnet.com/8301-13727_7-20083707-263/managing-mac-os-x-lions-applic ation-resume-feature/?tag=mncol;title

  • How do I create a fixed layout landscape-only epub3 in Indesign?

    Hi
    I have been trying to create a fixed layout epub3 from indesign without results.
    What I've done is to create a book with 4 pages in layout format 1034px/768px, each of them with text and pictures. I gave the text a style with the paragraph and exported in epub3 format.
    When I upload this to the ipad it works as a epub2, the layout is not fixed.
    When I open the files and read the code it actually is like a epub2, there is no fixed layout meta tag, there is no page dimension in each page, in the css the body size is auto and so on.
    I also opened the files and added without any result the following in the .opf file.
    <meta property="rendition:layout">pre-paginated</meta> (this should create the fixed layout option)
    <meta property="rendition:orientation">landscape</meta> (this should create a landscape only view)
    <meta property="rendition:spread">none</meta> (this should create a one page at a time view)
    Is there a way of achieving what I want or it simply is a functionality not yet introduced?
    Thanks for any advice

    InDesign CS6 or earlier is not designed for creating fixed layout EPUB files. Essentially it would have to be done in a very painful, very manual process. Anne-Marie Concepcion describes the process in this Lynda.com video:
            Creating a Fixed-Layout EPUB      
    The Rorohiko product is the best thing going at the moment.

Maybe you are looking for