Selection issue with Multiple containers when text re-flows

Hi,
I am building an EPUB reader in Flex 4.51. using TLF 2.0.3. I have text running across multiple containers. We add the controllers dynamically to ensure that there are as many containers as the content can have. Now, we updateAllControllers when status of a graphic element changes or when there's an increase in font size. So, after each activity we add more controllers if required. The text and images correctly reflow to the next container in this case. However, the issue comes with selection. If a piece of text reflows from one container and moves to another, when we try to select it, it doesn't highlight.
The SelectionChange event triggers and the values are mostly correct but no highlighing. We noticed that if we remove all controllers and recreate them, the issue is resolved. But, we cannot remove and add containers each time font size changes.
Kindly help and let me know where can the issue be? Remember that the text correctly reflows to containers and it's only the selection that doesn't work. This is a very common scenario for a reflowable content holder so I am sure I am missing something obvious. Please help.

I found the root cause of the bug is in removeAndRecycleTextLines() of ContainerController.as. The private "_textBlock" properties of some paragraph elements are incorrectly set as null there. When we want to get TextLine from TextFlowLine by getTextLine(), because paragraph._textBlock is null, TLF actually recreates some new, unused TextLines to return, which are not the ones on the sprite....
The fixed function is as follows and the bold, italic lines is the fix. I just modified a condition. It passed all existing test cases. I'm not sure it could be all right with your project. If it is still not OK for any of your scenarios, please tell us and we will appricate your feedback.
private function removeAndRecycleTextLines (beginIndex:int, endIndex:int):void
            var backgroundManager:BackgroundManager = textFlow.backgroundManager;
            var child:TextLine;
            var textBlock:TextBlock;
            for (var index:int = beginIndex; index < endIndex; index++)
                child = _shapeChildren[index];                   
                removeTextLine(child);
                CONFIG::debug { Debugging.traceFTECall(null,_container,"removeTextLine",child); }
                // when we've removed all the lines in the paragraph in shapeChildren, run through the textBlock and if all lines are not in view,
                // release the lines from the TextBlock, and release the TextBlock itself.
                if (child.textBlock != textBlock)       
                    if (textBlock)
                        releaseLinesInBlock(textBlock);
                    textBlock = child.textBlock;
            // Bug #2988783  -By Jin Huang
            // releaseLinesInBlock() be called here only when
            // 1. the end of final container
            // 2. the end line of TextBlock is the end line of the container
            if (textBlock && (textBlock.lastLine == child || flowComposer.getControllerIndex(this) == flowComposer.numControllers - 1))
                releaseLinesInBlock(textBlock);
            // Recycle lines not in view and not in the TextBlock
            if (TextLineRecycler.textLineRecyclerEnabled)
                while (beginIndex < endIndex)
                    child = _shapeChildren[beginIndex++];
                    // Recycle if its not displayed and not connected to the textblock
                    if (!child.parent)
                        if (child.userData == null)
                            TextLineRecycler.addLineForReuse(child);
                            if (backgroundManager)
                                backgroundManager.removeLineFromCache(child);
                        else
                            var tfl:TextFlowLine = child.userData as TextFlowLine;
                            if (tfl && tfl.controller != this)        // don't release lines that belong to other containers
                                continue;
                            if (child.validity == TextLineValidity.INVALID || (child.nextLine == null && child.previousLine == null && (!child.textBlock || child.textBlock.firstLine != child)))
                                child.userData = null;
                                TextLineRecycler.addLineForReuse(child);
                                if (backgroundManager)
                                    backgroundManager.removeLineFromCache(child);

Similar Messages

  • Since I've installed Mountain Lion, I am having lock up issues with multiple programs. MS Outlook has crashed and I've lost all my folders. HELP?

    Since I've installed Mountain Lion, I am having lock up issues with multiple programs. MS Outlook has crashed and I've lost all my folders. HELP?

    okay I've finally been able to get tor and all the other programs to work according to my plan the only thing that's still making problems is that iptables doesn't work as I want it to, when I start chromium without proxy settings privoxy doesn't seem to forward the information to polipo.. do I need to add another rule to iptables.rules in order for the program to know it has to reroute the information again or how can I get this to work? and is there any way to run rtorrent with proxy support?
    anyway, problem 2 and 3 are still to be solved.
    and does anybody know where i can get a good dansguardian blacklist that was not designed for 6 year old children and for which I don't need to subscribe? I'm still getting these partypoker popups -.-
    //e: with iptables it's the same thing as described in the first post. https works, http doesnt. I get the output "Invalid header received from client." on http sites. still no idea why though.. (and the https-version of torcheck.xenubite says i'm tor unprotected while starting the browser with iptables)
    Last edited by deF291 (2011-04-23 16:16:31)

  • We run an iMac 3.4 GHz I7 for our church worship service; we haven't upgraded to Mavericks because we heard about issues with multiple screens crashing.  Has this issue been resolved?  Thank you!

    We run an iMac 3.4 GHz I7 in our church worship service; we have front screens and a stage display monitor ; we haven't upgraded to Mavericks because we heard about issues with multiple screens crashing.  Has this issue been resolved?  Now that we are 2 upgrades behind, I'm getting little concerned.  Thank you!

    Oh, well that was a whole other kettle of fish:
    Oh the G4 I attempted to install iLife '08 before Lepoard was available. About the only thing that installed cleanly was iPhoto. I ended up reinstalling everything back to iLife '06, and then upgrading back to the current stable version of the iLife '06 version. I didn't attempt a reinstall until after I upgraded to Leopard.
    When I did reinstall, I made a iLife '06 folder, copied all iLife apps into it, and upgraded. Seemed to work, except for the part where iMovie gets left behind and iDVD is only mostly functional.
    When I installed on the other 2 machines, it was after installing Leopard and all upgrades. On those 2 machines, I didn't bother with the copy, I just moved everything to the iLife '06 folder I created, and did a fresh install.
    I didn't have to do anything with the iPhoto Libraries, that I can recall.
    I always do an upgrade, never an archive and install. I've never had a problem with this back to 10.1 or 10.2.

  • I have an issue with the Containers / Triggers.

    I have an issue with the Containers / Triggers. My issues is with the blank composition, when I edit the container to the size I need and place the target inside of that.. which is what I thought I needed to do.. Target = Image and container is the housing for said image. I want the image to appear in a certain location on my site though when I preview it. It does not display where I placed the container/ target.
    I used a blank composition at a certain size no fills no stroke, setup the 8 triggers as "buttons" which all work as expected. container is placed in a certain area and target is inside that scaled as needed. My images do not display inside of my container. Any help??

    Well I figured it out. Though I'd like to know why it still wasn't working with the previous settings.. I'll explain it better here.
    click on widgets library and add a blank widget to the page, add say 4 triggers giving them an image for their fill. Add a roller over state with its proper image. Move to the container / target boxes. My container has no fill or stroke. All 4 of them sit on top of one another. So they all fall in the same location. Add the images to the targets that match the triggers. So trigger A goes to container / target A and so on. My options for the widget were set to lightbox. not showing prev. next button or anything fancy. As soon as you preview it.. on browser, the images appear to land in the middle of the page. ( think it's due to lightbox setting) as soon as I changed the option to "stacked" it appeared to work as expected.
    So why does the lightbox default to the center of the page when you are viewing the images? Why can't it just load from where I had placed the target / containers?

  • I need to divide selected row into multiple rows when i navigate  ADF 11g

    Hi
    I'm using jdeveloper 11.1.1.2.0 with ADF 11g.
    I need to divide selected row into multiple rows when i navigate to other page . Scenario - in first page i'm displaying some records with columns like empno , empstatus , empworkdepts ,curdepts
    Here empworkdepts gives the numeric number like no of departments work shifts 3 or 4 or 5. when i select any particular employee and fire next button to navigate next page.I have to divide the selected employee with same information into multiple times based on the empworkdepts value.
    empno empstatus empworkdepts curdept
    001 eds 2 TS
    002 hr 1 FO
    003 eds 4 TS
    *004 eds 3 TS*
    now i selected employee 004 , when i navigate to next page.
    Empno EmpStatus EmpWorkDepts CurDept
    004 eds 3 TS
    004 eds 3 TS
    004 eds 3 TS
    i did with java code in bean .but not stable .
    any help............
    thanks advance.............
    Edited by: user9010551 on May 5, 2010 10:48 PM
    Edited by: user9010551 on May 10, 2010 11:31 PM

    user9086775 wrote:
    Hi Experts,
    I have a requirment where i need to fetch parts of a single row into multiple rows from a singlt Query, i am sure it is possible using Pivots but just cant figure out an approach. Any help on this is highly appriciapted.
    Requirment:
    This is a sample set record in a table
    Product     Sub Product          Name    Age
    New Car    Nissan                   Tom        49
    New Car    Nissan                   Jack         36
    Old Car      Audi                     Sam         24
    Old Car      Jaguar                  Pint          26
    Old Car      Audi                     Smith       41
    I need to be able to fetch the above data in the below fashion
    Product     Sub Product          Name    Age
    New Car
    Nissan
    Tom        49
    Jack        36
    Old Car     
    Audi            
    Sam        24
    Smith      41
    Jaguar                   Pint         26Please help with ideas as to how can i achive the above without using PLSQL.
    Thanks in advance!You should be doing this in the client on not in the DB. Use the reporting tool that you use to do this.
    For example if you are in SQL Plus you can use the BREAK command.

  • SPEL in Extended VO - Issue with Multiple Rows

    Hi,
    I have extended a seeded VO by adding a new attribute *'Course_Flag'* with attribute type 'Boolean' and Query Column type 'VARCHAR2' and i wa successfully able to personalize and view the data of the new attribute *'Course_Flag'* in the page as ('true' / 'false') aacording to the query where clause.
    Now after adding a new image with SPEL property as *${oa.LearnerCatalogCoursesVO.Course_Flag}* it will have an issue with multiple items.
    I mean the SPEL will take the first row value 'true' / 'false' and will be corrected rendered according to the value of the first row and ignore other rows values.
    Example: if the *'Course_Flag'* value of the first row is 'true' then all the images will be rendered and if the *'Course_Flag'* value of the first row is 'false' then all the images will be NOT rendered.
    Please advise if I've missed any step.
    Thanks in advance to all.
    Regards....Ashraf

    Dear Kali,
    I have added a new function to the seeded VO SQL +('XXARMS_TRG_EVALUATION_PKG.XX_COURSE_GOT_EVAL')+,
    SQL Statment :-
    select av.activity_version_id, avtl.version_name, av.language_id, av.start_date,
    av.end_date, av.version_code, i.category_usage_id, upper(avtl.version_name) AS SORTVERSIONNAME,
    XXARMS_TRG_EVALUATION_PKG.XX_COURSE_GOT_EVAL(i.category_usage_id, av.activity_version_id) Course_Flag from
    ota_act_cat_inclusions i, ota_activity_versions av, ota_activity_versions_tl avtl
    where i.category_usage_id = :1 and i.activity_version_id = av.activity_version_id and
    nvl(av.end_date, sysdate + 1) >= trunc(sysdate) and
    av.business_group_id = ota_general.get_business_group_id and av.activity_version_id = avtl.activity_version_id and
    avtl.language = userenv('LANG') and
    ota_learner_access_util.learner_has_access_to_course(:2,:3,avtl.activity_version_id) = 'Y'
    And it is retriving the correct data for each row and i did not write any code in the RowImpl.
    Thanks for your help in advance.
    Regards...Ashraf

  • Issue with Emoji icons when sent from iOS6 to iOS5

    Issue with Emoji icons when sent from iOS6 to iOS5, all icons appear as a square on the iOS5 message screen.
    Both iOS are the current version and the phones are 4S 64GB
    Anybody got this problem

    Hi!
    What kind of RFC do you use? If you use synchronous RFC the caller waits for the answer/result of the called function. In normal cases this should solve your issue.
    Regards,
    Volker

  • Hi BC, I have an issue with BC. When the shopping cart is used it takes stock out of inventory and h

    Hi BC,
    I have an issue with BC. When the shopping cart is used it takes stock out of inventory and holds it, regardless of whether or not a customer proceeds to purchase. OK.
    To make matters worse, the stock is only cleared from the shopping cart when the customer closes the browser - not when they close the shopping window.
    Now lets say a customer doesn't close their browser for a month - it happens! .. when their stock is finally returned it may throw out our stock levels that have in the meanwhile been adjusted. So their stock will be added on top of an accurate stock take, putting stock in that isnt really available.
    This is causing us mayhem.
    We have not yet seen if stock is actually returned at all. In the test we did today where we filled a shopping cart then closed the browser without making a purchase, the stock was not returned immediately. So we dont even know when it will be returned - thats IF a customer actually closes their browser. Any solutions out there?
    Jo

    Hi there,
    The way stock is managed in this situation is desirable for many in that case otherwise shopping on a site and adding to cart would not be viable or use friendly.
    What you mention about not closing a browser though is a case that is not true. IF you go into the shop settings in the admin you can see the cart restore timer which is by default 24 hours but you can change this to as low as 1 hour if you wish.

  • Creating Select List with multiple columns

    I want to create a select list with multiple columns. I followed the demo application model described in the by Denes Kubicek (Currently my reference for APEX !!)
    The code is as follows:
    CREATE OR REPLACE FUNCTION getcrops(p_cropid IN NUMBER)
    RETURN VARCHAR2
    IS
    v_cropid VARCHAR2 (400);
    v_fcode VARCHAR2 (400);
    v_product VARCHAR2 (400);
    v_var VARCHAR2 (400);
    v_fname VARCHAR2 (400);
    v_acres VARCHAR2 (400);
    v_style_start VARCHAR2 (400);
    v_style_end VARCHAR2 (400);
    v_return VARCHAR2 (400);
    BEGIN
    FOR c IN (select "CROP"."CROPID" as "CROP ID",
         "CROP"."FIELDCODE" as "FIELD CODE",
         "CARROTPRODUCTLIST"."CARROTPRODUCTNAME" as "PRODUCT",
         "VARIETYLIST"."VARIETYNAME" as "VARIETY",
         "FIELD"."FIELDNAME" as "FIELD NAME",
         "CROP"."SIZEINACRES" as "ACRES"
    from     "FIELD" "FIELD",
         "CARROTPRODUCTLIST" "CARROTPRODUCTLIST",
         "VARIETYLIST" "VARIETYLIST",
         "CROP" "CROP"
    where "CROP"."CARROTPRODUCTTYPE"="CARROTPRODUCTLIST"."CARROTPRODUCTID"
    and     "CROP"."VARIETYID"="VARIETYLIST"."VARIETYLISTID"
    and     "CROP"."FIELDID"="FIELD"."FIELDID")
    LOOP
    v_cropid := TO_CHAR (c.'CROP ID', 'FML999G999G999G999G990');
    v_fcode := c.'FIELD CODE';
    v_product := c.'PRODUCT';
    v_var := c.'VARIETY';
    v_fname :=c.'FIELD NAME';
    v_acres :=c.'ACRES';
    FOR i IN 1 .. 12 - LENGTH (c."CROP ID")
    LOOP
    v_cropid := v_cropid || ' ';
    END LOOP;
    FOR i IN 1 .. 12 - LENGTH (c.'FIELD CODE')
    LOOP
    v_fcode := v_fcode || ' ';
    END LOOP;
    FOR i IN 1 .. 12 - LENGTH (c.'PRODUCT')
    LOOP
    v_product := v_product || ' ';
    END LOOP;
    FOR i IN 1 .. 12 - LENGTH (c.'VARIETY')
    LOOP
    v_var := v_var || ' ';
    END LOOP;
    FOR i IN 1 .. 12 - LENGTH (c.'FIELD NAME')
    LOOP
    v_fname := v_fname || ' ';
    END LOOP;
    FOR i IN 1 .. 12 - LENGTH (c.'ACRES')
    LOOP
    v_acres := v_acres || ' ';
    END LOOP;
    v_return := v_cropid || v_fcode || v_product || v_var || v_fname || v_acres;
    END LOOP;
    RETURN v_return;
    END;
    I created this anonymous Pl/SQL function at a application level ..Then I followed up to create a select list with a function inside. However I could not create select list with the command suggested in the demo which is
    select getcrops(cropid) d, cropid r from crop;
    APEX (2.1) returns a error message. What am I missing ? Should the function be called from somewhere else after creating a regular select list..? Where the functions (Pl/SQL) should be ideally stored for application level access..? and for across application level access ? How can I check the function works good. Help is appreciated.

    Still really one column.
    If they need to be independent then you've got to have three selection lists.
    %

  • Selection list with multiple columns

    How can i create a selection list with multiple columns?

    Still really one column.
    If they need to be independent then you've got to have three selection lists.
    %

  • Select list with multiple columns

    I want to create a select list with multiple column option. What are the options. Any developments in apex 3.0.1 ? Thanks in advance. I tried the tutorials by Kubicek.
    I am kind of stuck to see the function entry inside LOV definition returns a error.

    Still really one column.
    If they need to be independent then you've got to have three selection lists.
    %

  • Watermark with multiple rows of text, Is it possible?

    Hi everyone,
         One of our clients want the whole page filled with watermark with multiple rows of text, I cannot find related properties on the watermark configuration page, is it possible?
    Thank you in advance.

    Multi-line Dynamic Watermarks are available from ES3 onwards. You can create multiple Watermark text elements to have more than one line in the Watermarks. Please see http://help.adobe.com/en_US/livecycle/10.0/AdminHelp/WSb96e41f8a4ca47a94897a78313098c91af6 -8000.html
    Regards,
    Neerav

  • Issue with BAPI_ACC_***_TRANSFER_POST (when trying to execute as per ABT1N)

    Hello experts,
    For this thread, please check the following link:
    [Issue with BAPI_ACC_***_TRANSFER_POST (when trying to execute as per ABT1N);
    Thanks and Regards,
    Daniel.

    Hi Experts,
    The question has been answered as per the following "link":
    [Issue with BAPI_ACC_***_TRANSFER_POST (when trying to execute as per ABT1N);
    Daniel

  • I  have an issue with speaker/microphone. when i call or i  recive a call the person on the other side can not hear me.

    i  have an issue with speaker/microphone. when i call or i  recive a call the person on the other side can not hear me.

    Hello aalapdesai112,
    Lets see if we can get you back to taking calls normally again. Start your troubleshooting with the article below and go through checking to making sure that you are up to date with your iOS as well as a simple restart on your iPhone. 
    If your voice is too faint or sounds unclear using iPhone, or iPod touch
    http://support.apple.com/en-us/HT203792
    Regards,
    -Norm G. 

  • RSA1 Document - Issue with "multiple selection" Characteristic

    Hi,
    I have the following issue with a web template showing monthly reporting results (act/plan/var) for a specific cost center broken down following a cost element hierarchy.
    My purpose is to attach each month some comments and these comments are made at the query level, not for each individual cost element.
    However, as explained in note 501593, when creating my document, I have to restrict my cost elements since they are regarded as "multiple selections".
    I could go and limit from 6 to one single value through table RSODADMIN but I never know for sure that this single cost element would always show up in my query.
    In RSA1 > document > properties of the comment, is there any way for me to go and input a range for my cost elements, instead of having to enter cost element by cost element ?
    Thx
    Stéphane

    Hi,
    I have the following issue with a web template showing monthly reporting results (act/plan/var) for a specific cost center broken down following a cost element hierarchy.
    My purpose is to attach each month some comments and these comments are made at the query level, not for each individual cost element.
    However, as explained in note 501593, when creating my document, I have to restrict my cost elements since they are regarded as "multiple selections".
    I could go and limit from 6 to one single value through table RSODADMIN but I never know for sure that this single cost element would always show up in my query.
    In RSA1 > document > properties of the comment, is there any way for me to go and input a range for my cost elements, instead of having to enter cost element by cost element ?
    Thx
    Stéphane

Maybe you are looking for

  • Duplicate Rows to be displayed.Please help

    This is a repeat question.No offence I have an inbuilt function (called xml.extract)that returns an ISIN for an associated code. When I run this code I get 2 codes for the same ISIN returned SELECT a.code FROM table a and xml.extractval(a.xml,'/under

  • Error With Uploading Images for Content Manager

    Hi Guys I have tried to upload an image into Content Manager..... and on the concurrent request i get a failed error..+---------------------------------------------------------------------------+ Content Manager: Version : 11.5.0 - Development Copyri

  • About License "Can I install OEM9i on my PC? If I have 8i and 10g License."

    I have License of Oracle8i & EBS11i running on Solaris 5.8 and License of Oracle10g & Pelplesoft running on AIX P550. I'm know now have new OEM 10g grid...., But I can't setup to use it. I'm ever use OEM 9i and found it good than OEM 8i. I like it. P

  • Need Help creating a file download button

    Hello again, i am trying to make a button that when clicked will prompt the user to downalod a file to a target directory of the users choice. I have tried using URLRequest but it just opens the mp3 on another window with qiucktime which, i suspect,

  • JSONReader Array as Multi-Value Attribute

    Hi, I am reading data into Endeca using the JSONReader. Is it possible to map a JSON array into a multi-value attribute? e.g. if the data is {"id":"1", "title":"this is a book", "themes":["book", "read", "happy"]} How do I read and store the themes i