Commit Graph

724 Commits

Author SHA1 Message Date
Dave Hoover 06bcdeea14 Don't always claim unpacking resources is a mere 1 second from completion.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@730 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-05 23:15:39 +00:00
Ray Greenwell 22603206cd Added avoidOtherPopups. A hole was rabbitted while I debugged
that assigning to Rectangle.topLeft sets x and y and width! and height!
Gah.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@729 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-04 00:55:18 +00:00
Dave Hoover 8b899014ef Let's reorder those to go clockwise around the compass
(and match the set of cardinals in yohoho that I want to replace with this)


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@728 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-03 19:00:09 +00:00
Dave Hoover 1680e5135b Cardinals.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@727 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-03 18:53:20 +00:00
Mike Thomas 42aa38f832 We really need to adjust _priorCurrent regardless of whether this particular call to elapsed() is at a driftRatio of 1.0 or not - the next one might not be, so we need to keep it up to date. Otherwise, we could potentially yank _startStamp around by minutes or hours due to a stale _priorCurrent.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@726 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-02 23:52:23 +00:00
Ray Greenwell 7b3544fd2b - Added setFocuable().
- createField calls it.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@725 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-12-01 21:12:09 +00:00
Charlie Groves 411afaf415 Skip on toString if baseTileIds is null in addition to when width is 0. When
digester is logging - which happens when log4j is added to the classpath but
not configured - it prints Sections out while they're being initialized and
have a width but no baseTileIds.



git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@724 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-27 00:46:24 +00:00
Mike Thomas 1dc123281b Add a new play method that allows specification of a position for the sound source.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@723 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-26 23:56:40 +00:00
Ray Greenwell 714ad7e725 Another SimpleButton derivative for skinning with a bitmap.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@722 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-24 23:15:07 +00:00
Ray Greenwell 66386a90af Use toBitmapData.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@721 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-24 23:14:47 +00:00
Ray Greenwell cecdbfa320 Added toBitmapData.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@720 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-24 23:14:33 +00:00
Ray Greenwell 8584678701 Player BAM5 told me about code his friend Shango wrote, for
extrapolating the total duration of an mp3 while it was loading.
Sure enough: we have length (so far), bytesLoaded and bytesTotal.
So: do that. It works pretty well!

Too bad we can't do something similar for FLVs that don't have metadata.
:( (there is no "current length" property, just a current position.
So any time estimate would get worse and worse as the bytes advanced
past the play position.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@719 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-19 05:19:38 +00:00
Ray Greenwell be24ecee84 This is referenced by MediaContainer, so it's compiled in,
but we don't actually use it anywhere in whirled.
Made it extra stupid simple: click to play/pause, with no
other controls.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@718 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-19 00:12:56 +00:00
Ray Greenwell 714aa2adfb We want to ensure we sound out position, so call regular stop()
after we autorewind.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@717 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-19 00:10:56 +00:00
Ray Greenwell 96c892ce62 Bugfix: don't autorewind if someone seeks to the end while paused.
Feature: if there is no metadata telling us the duration, well then
we're up the old poo river. But what we can do is whip out our
trusty paddle and continually call the highest position we've seen
the duration. It makes playback a little weird, but allows seeking
and so is a step in the right direction.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@716 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-18 22:07:02 +00:00
Ray Greenwell 73a1102fe7 Simplified. Turns out the x/y coords of the states are honored,
so I don't need to wrap the downState in a Sprite.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@715 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-18 03:29:58 +00:00
Ray Greenwell 021a49c0ee Do for simple flash buttons what ImageButtonSkin does for flex Buttons.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@714 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-18 03:02:20 +00:00
Ray Greenwell 93a4814155 Just as clear without this const.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@713 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-17 16:24:49 +00:00
Ray Greenwell 5bc77aa0d0 Possible type 3 optimization, but well... it doesn't really make the code
weirder, but it does add a bit more code.
( http://smallwig.blogspot.com/2008/04/smallwig-theory-of-optimization.html
  mdb pointed this post out to me.)
It just bugged me that we use this player to play background music
in whirled, and in that circumstance 99% of the time nobody cares about
these events, so why have a timer to calculate and fire them off?


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@712 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-17 16:14:07 +00:00
Ray Greenwell 526db3bb05 This shouldn't happen, but it did once for me. Heisencope.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@711 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-17 06:17:09 +00:00
Ray Greenwell ee72820b54 Ouch, I changed that to 25 a while back while testing, but we want 250.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@710 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-17 05:59:03 +00:00
Ray Greenwell 5161e49bd4 Wow, when you tell a sound to loop, the position just continues
to increase, up past the duration. Seeking in those mode also
causes it to get wiggy and freak out. So don't have flash loop it,
but just loop it ourselves by autorewinding and playing again.
Also, just autorewind and pause if not looping, which I had
wanted to do anyway.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@709 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-17 05:51:20 +00:00
Ray Greenwell 8cd31c9564 Ah-ha. After testing id3 tags with 3 different mp3 files that all
should have had id3 tags, and trying everything, I tried one
more mp3 file: bingo.
Added MediaPlayer.getMetadata() and a METADATA event.
Contents of metadata vary by media being played and are open for
interpretation by users of the player.
FLV video returns their metadata object.
MP3 audio returns id3 tags.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@708 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-16 17:11:35 +00:00
Ray Greenwell 9da0886afc Dammit! Id3 tags are not working at all. I'm checking the crossdomain.xml. Grr!
Removed debugging.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@707 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-15 02:51:04 +00:00
Ray Greenwell 2b81e25445 - AudioPlayer interface extends MediaPlayer.
- Mp3AudioPlayer implements AudioPlayer.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@706 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-15 02:21:51 +00:00
Ray Greenwell 3ce7fc7f6a More prepatory renaming and refactoring. Nothing of interest.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@705 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-14 21:43:33 +00:00
Ray Greenwell decb92fc08 Repackaging in preparation for refactor.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@704 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-14 21:29:34 +00:00
Ray Greenwell 0fdf0da9d5 Nixed debug logging.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@703 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-13 02:10:16 +00:00
Ray Greenwell 853b318a2c Cleanup.
Since MediaContainer imports this, I've got half a mind
to just reduce this simple player back down to play/pause
and have MsoyVideoDisplay subclass this.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@702 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-13 00:40:38 +00:00
Ray Greenwell 6f82c8b7a9 As usual, flash sucks and the NetStream object notifies us when it has seeked,
but reading the position value off the object returns the old position.
If we wait 1 frame we get the updated value.
Fuckers.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@701 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-13 00:39:46 +00:00
Dave Hoover e92d57e315 Some warning cleanups, widening, and varargs logification.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@700 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 18:45:13 +00:00
Ray Greenwell 9931cae098 Comments.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@699 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 18:34:03 +00:00
Ray Greenwell 59536d47ad Bugfix: stop the positionTimer when we unload.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@698 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 05:32:43 +00:00
Ray Greenwell f5e900eedd - Broke out creating the video UI into a method.
- Bank on the video UI having sane width/height. 


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@697 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 05:26:58 +00:00
Ray Greenwell e4dd02746c Broke unloading the media out into its own method.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@696 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 02:48:19 +00:00
Ray Greenwell d7e607972d Out with the old.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@695 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 00:30:15 +00:00
Ray Greenwell b18ac89db9 Cleanup.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@694 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-12 00:29:59 +00:00
Dave Hoover c4af53338c Rejigger component rendering order a bit so that individual components can have their own
priority overrides, since unfortunately, not all male/familiars are created equal.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@693 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-10 23:02:00 +00:00
Ray Greenwell 6294232dce Roll this back. You don't even want to see the unchecked-in code I also trashed.
Too bad the bitchy comment about adobe goes too.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@692 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-10 20:54:56 +00:00
Ray Greenwell e14212f5b4 Add a way to set the HTML text.
Oh yeah, links don't work unless the field is selectable. WHY?
Carbomb adobe.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@691 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-10 20:16:44 +00:00
Michael Bayne dcfc762d1f Added isRunning().
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@690 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-08 00:11:00 +00:00
Michael Bayne ab024a3054 Added isRunning().
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@689 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-08 00:10:17 +00:00
Ray Greenwell b6f41f765e Autoplay FLVs, for now, like the old player did.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@688 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-06 20:09:32 +00:00
Ray Greenwell 361d5aeb61 Comment out the advanced controls, they're not ready for prime-time.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@687 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-06 20:09:17 +00:00
Ray Greenwell 6e7dbada64 Dragging the knob to seek.
Works not-so-well with youtube. I'll revisit later...


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@686 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-04 23:16:07 +00:00
Ray Greenwell 3ff4c5de51 Just redispatch Event.COMPLETE from our Loader.
This fixes the AVRG loading button...


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@685 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-04 23:15:10 +00:00
Ray Greenwell 1e33a90f14 Checkpoint: seeking, tweaking... no peeking!
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@684 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-04 03:52:34 +00:00
Ray Greenwell cda3d6f94e Headless building for happy Mac development.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@683 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-04 01:40:56 +00:00
Ray Greenwell 343b24728c Tidied logging, including commenting out super-annoying unload messages.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@682 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-01 03:15:04 +00:00
Ray Greenwell 666999284e Use the new video player.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@681 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-11-01 03:10:45 +00:00