Jump to content
Search Community

Big Bad Roo

Members
  • Posts

    40
  • Joined

  • Last visited

Contact Methods

Big Bad Roo's Achievements

1

Reputation

  1. Ahh - this is one instance for mobile that I can load MCs into and out of that is the scrolling area for the whole screen. I realised I really needed to have ALL of my screens be scrollable, and this would be better that having a scroll instance for each screen's class. Cheers Jack
  2. I think I'm not understanding some class fundamentals. To set up that scrollable.setScrollClip(myClip); scenario, wouldn't you need... private var scrollable:Scrollable = new Scrollable(); ...in every class that uses it, and therefore you'd have (if you have 30 classes controlling 30 screens), 30 separate instances of scrollable, ie 30 separate scroll screens? How do I have just one Scrollable that all classes have access to using scrollable.setScrollClip(myClip);? The only way I can see how is with a getter/setter, but then you'd have to inject the model with that G/S into all your classes that need scrolling.
  3. Thanks Jack That's kind of what I've done, but what if you have many classes that you want to access the one instance of Scrollable? My current problem is I have many screens I want to use in Scrollable (one displayed at a time), so I'm ending up with a huge class accomodating all these screens and their logic. I'd rather have many smaller classes, all able to send movieclips to one central Scrollable, but I'm unsure of the best way to set it up - have classes send their clips to a central model that talks to Scrollable, or create Scrollable, and inject it into the constructor of all the classes that need access to scrolling as in... scrollable.scrollClip = null; scrollable.scrollClip = _myMovieClipFromMyClass; each time I want to remove the old scrolling clip and add a new one.
  4. Hi I've set up a class that uses the ThrowPropsPlugin - it accepts a movieclip for scrolling in an AIR iOS project. Currently I'm setting this class up as a new instance in every class I need scrolling in, but it seems wasteful. Is there a standard way to have one such scrolling class, that all your classes send movieclips to for scrolling? Is it a matter of having a var in a global model that all classes send movieclips to, and then that var dispatches the movieclip to the scrolling class? Or is a better way to create the class once, and inject it into the constructor of every class that needs scrolling? Cheers
  5. OK - this way has worked wayyyyy better. The most items ever displayed are 57, but it feels continuous when scrolling through. Cheers Carl.
  6. Hi When I navigate away from a page that contains a blitmask, the blitmasks's content mc stays visible above the page I navigate to. I was getting around it by killing the blitmask and recreating one when navigating back to it's page, but I figure there must be a way to just hide it. mc.visible = false, or even removeChild.mc aren't hiding the mc I send to the blitmask. Cheers
  7. Better question (after discovering and playing with LoaderMax), with regard to displaying a loaded remote image... The display in my AIR project is set up like this... - stage has been passed into my controller, and I'm setting up the main display objects like so... _stage.addChild(mc);// a container mc mc.addChild(_UI); (UI made in Flash Pro) _UI.addChild( mySPR ); The rest of my display objects are created dynamically and added to mySPR - everything displays fine. I used the first sample code on the LoaderMax page https://www.greensock.com/loadermax/ to test download a remote image off my server that I want to load into mySPR. On running - it's telling me "LoaderMax 'mainQueue' is complete!", but I can't see the image. With the display set-up above in mind, what do I need to change in the following lines of code to have the image appear in mySPR? queue.append( new ImageLoader("https://www.mysite.com/books/mylogo.jpg", {name:"photo1", estimatedBytes:2400, container:mySPR, alpha:0, width:250, height:150, scaleMode:"proportionalInside"}) ); function completeHandler(event:LoaderEvent):void { var image:ContentDisplay = LoaderMax.getContent("photo1"); TweenLite.to(image, 1, {alpha:1, y:100}); trace(event.target + " is complete!"); } Is the downloaded image now in 'image'? I tried mySPR.addChild(image), but no go there either. Thanks for taking a look.
  8. Hi guys Just wondering if there is a Greensock solution, or if someone can guide me to what to research for... ...loading and displaying a series of images from a server into mobile device native apps? Like how the Facebook app loads profile images into your newsfeed? Cheers
  9. re autoUpdate - do I need it then? What does it do if the target position has changed that wouldn't happen if you didn't have autoUpdate on? re target size - the width is always 640, and the height is roughly 10 000 for 50 items loaded each pagination search (give or take depending on the text involved). So 4 pagination searches will give you a total height of 40 000. I'm changing my strategy as I've realised this isn't sustainable - continually adding to the size of the target bitmap each search will kill everything pretty quickly. I'm now making it so that 60 items is the most EVER shown, and coding backwards pagination as well as forwards - this will make the bitmap at most 640 x 12000. Backwards pagination will get it's data from the local array holding items already searched, so it should be very fast - just rebuild the sprite holding the search text, and readjust position. Forwards pagination does what it currently does - gets the next 50 items from the server. I'm about 1/2 way through coding it - I'll let you know how it goes. Thanks Carl
  10. 'twas a 'how long is a piece of string' question I'll admit! Cheers Carl.
  11. Hey guys How do you handle/speed up updating display changes with large scrolling data? eg if I click a button in the scroll area, I now need to update the blitmask, which can take a while, and hang the display (button appears sluggish) or stop any new scrolling until it's updated. Also, is blitMask.autoUpdate = true; a substitute for calling blitMask.update(null, true); after any display changes like buttons being switched? I've set blitMask.autoUpdate = true; but it's not updating the blitmask Cheers
  12. My bad - I meant to ask where should... onStart:blitMask.enableBitmapMode go in the above code?
  13. Hi My project is set at 12fps as it's a blog type app, so no serious animation needed, except when scrolling the text. Just wondering is that's a good rate when using throwprops? I see some examples are at 60fps - what's less taxing for, say, an iPhone? Also, do you need to adjust (in mouseMoveHandler): if (t - t2 > 50) { y2 = y1; t2 = t1; y1 = mc.y; t1 = t; } ...according to your frame rate? Cheers
×
×
  • Create New...