Commit Graph

88 Commits

Author SHA1 Message Date
Glenn Maynard 9b94f66bc0 fix leak 2006-09-20 22:09:44 +00:00
Glenn Maynard 8983d620c6 PrepareItemText -> GetThemedItemText 2006-09-01 04:44:30 +00:00
Glenn Maynard e6d1712c27 move OptionRowDefinition into OptionRowHandler
(want OptionRowHandler to be easily usable without OptionRow; ORH is
really part of ORD, not OptionRow)
2006-09-01 04:37:39 +00:00
Glenn Maynard 3f468cb30a move OptionTitle into OptionRowHandler 2006-09-01 04:29:24 +00:00
Glenn Maynard bce305a0bf zoom long lines to fit if reasonable 2006-03-06 04:29:33 +00:00
Glenn Maynard bbf668ab97 remove unused 2006-02-27 05:54:21 +00:00
Glenn Maynard 264120c28c unused 2006-02-27 03:28:37 +00:00
Glenn Maynard c2243b0b0e ScreenOptions fading is a headache. We move rows up and down, and
fade them in and out at the same time; we do this by tweening the whole
row up and down, and fading each part of the row.  This is a big pain,
because we're also tweening each part for other reasons, and these
tweens tend to collide.  The whole thing is brittle and complicated,
and it's making fixing other problems a pain.

Try it a little differently: to fade the whole row, tween the alpha
along with the position of the whole row.  Then, manually propagate
the changing alpha value to each part, using BaseAlpha, so it doesn't
affect other tweens.

This also helps segregate the fading: with the exception of the actual
propagation, OptionRow doesn't have to know anything about it.  Before,
it had to constantly be careful that any tweening operations didn't
collide with the alpha tweening; often, one or the other would be cancelled,
resulting in either the change not happening at all, or snapping instead
of fading.

(This is still a hack, but it's more manageable; it puts control of high-level
tweening entirely in SOptionsMenu's control, instead of half in OptionRow.)
2006-02-27 03:04:56 +00:00
Chris Danford 95c88765a0 fix options rows tween from top of screen instead of initially being in the row's position 2006-02-10 04:33:54 +00:00
Glenn Maynard 2e95edf9da PositionIcons(pn) 2006-02-03 09:31:51 +00:00
Glenn Maynard cb0c7ce59d Set up tsDestination directly. It doesn't make sense for a
function named "UpdateEnabledDisabled" to do this, and we
don't need to delay it anymore as GetWidthXY says (that was
before we moved the text into a frame).
2006-01-30 08:06:31 +00:00
Chris Danford 7f821e8cfc CString -> RString 2006-01-22 01:00:06 +00:00
Glenn Maynard 544733b287 don't have to import both players at once, so AfterImportOptions takes pn 2006-01-19 01:52:18 +00:00
Glenn Maynard b158147319 pull pn loop out of UpdateText 2006-01-19 01:01:13 +00:00
Glenn Maynard 49b5375af8 Split out ResetFocusFromSelection.
Don't reset m_iChoiceInRowWithFocus in ResetFocusFromSelection
for SELECT_MULTIPLE or SELECT_NONE.  That's done by ChoicesChanged.
2006-01-19 00:29:22 +00:00
Glenn Maynard aab0edf1c2 merge dupe code 2006-01-18 04:56:39 +00:00
Glenn Maynard a3dc5596de OptionRow::Reload doesn't take an OptionRowDefinition.
Implement Reload() explicitly, so we can clearly short-
circuit for static rows.

Fix up ScreenOptionsEditCourseEntry (broken during the
course of things).
2006-01-18 01:34:45 +00:00
Glenn Maynard 7a3282ea9a unused 2006-01-17 23:57:19 +00:00
Glenn Maynard b60126a261 remove redundant m_RowDef 2006-01-17 22:16:58 +00:00
Glenn Maynard a42ba8e13f simplify 2006-01-17 21:40:39 +00:00
Glenn Maynard 3c63e09ca3 Previously, OptionRowHandler was owned and freed by
ScreenOptionsMaster (and ScreenOptionsManageProfiles).
Make it owned by OptionRow; the only pointer to them
is where they're stored in the OptionRow.  This
eliminates the remaining association between m_OptionRowHandlers
and m_pRows; that was confusing, because they're in
different places, and aren't always the same size.  It
also simplifies using OptionRowHandlers.
2006-01-16 22:55:57 +00:00
Glenn Maynard 27cdcd6b3e const 2006-01-16 19:58:22 +00:00
Glenn Maynard ae60708bcb redundant, Init does this 2006-01-16 04:03:05 +00:00
Glenn Maynard 51873e1818 cleanup 2006-01-16 04:02:19 +00:00
Glenn Maynard 2ac3a986a0 simplify 2006-01-15 23:33:29 +00:00
Glenn Maynard 1d186c481d const fix 2006-01-15 07:12:05 +00:00
Glenn Maynard 6be6053227 const fix 2006-01-15 07:10:05 +00:00
Chris Danford 2d8b30e049 polish 2005-12-06 12:41:33 +00:00
Chris Danford 1c0dc2aad8 LABEL_ -> TITLE_ 2005-12-06 04:21:00 +00:00
Chris Danford d33daeb6f9 add separate explanation name so that rows with no title can still have an explanation 2005-12-03 20:39:11 +00:00
Chris Danford 8cb7360ab6 bAllowThemeTitles -> bAllowThemeTitle 2005-11-30 22:37:51 +00:00
Chris Danford 42f056dfdb remove THEME_ITEMS and THEME_TITLES. Always theme unless the OptionRowData has been marked !allowTheme 2005-11-30 04:32:33 +00:00
Chris Danford 299e1f7d68 add memcard blacklist by OsMountDir and UI to disable specific drives 2005-11-27 01:50:10 +00:00
Chris Danford 24440aa3bf move Trasform caching out of ActorScroller and into LuaExpressionTransform so that ScreenOptions can use it too.
add RowOn/OffCommand to ScreenOptions
2005-09-03 17:37:42 +00:00
Chris Danford dd28d5e354 add BulletOnCommand 2005-08-30 07:58:53 +00:00
Chris Danford c885d87f4a Use a lua transform function to position SOptions rows instead of having a Y metric for each row 2005-08-15 07:51:16 +00:00
Glenn Maynard 2f8f782c47 use Copy() 2005-07-18 23:01:06 +00:00
Glenn Maynard 5bf4e9323f don't set up actors that we're not using; we create lots of OptionRows 2005-07-18 21:25:07 +00:00
Glenn Maynard cece1f837c don't set up actors that we're not using; we create lots of OptionRows 2005-07-18 21:03:43 +00:00
Glenn Maynard 0fcda13da1 temp fix for double-free 2005-07-16 10:16:23 +00:00
Chris Danford 146c505c5a change sprBullet to an AutoActor 2005-07-16 07:01:48 +00:00
Glenn Maynard d8bf6df4aa move metrics into OptionRowType, too 2005-07-16 03:23:53 +00:00
Glenn Maynard b925b2d7ca instead of loading actors inside OptionRow, load a single copy of each
one we need, and then make copies as needed.  This avoids lots of
extra loading (which can be slow, even with refcounted data; lots of path
lookups, etc).  (Trying to get this to the point where we can construct new
OptionRows for a menu without making a whole new menu.)  This approach
means we don't lose the potential to have different sTypes of OptionRow
in a single menu.  (The annoying bit is that any actor we copy has to handle
copying, which is tricky for ActorFrame and doesn't work yet for AutoActor.
Working on it ...)
2005-07-16 02:51:17 +00:00
Glenn Maynard e8656a2420 hide 2005-07-15 23:31:58 +00:00
Glenn Maynard 618f71f3d4 separate initializing text and setting m_iChoiceInRowWithFocus 2005-07-15 06:54:10 +00:00
Glenn Maynard ff5f5f4035 separate frame for deleted objects 2005-07-15 06:34:06 +00:00
Glenn Maynard d9068e601d LoadOptionIcon -> SetOptionIcon 2005-07-15 05:43:10 +00:00
Glenn Maynard 5c441a5fdf We load lots of the same thing in OptionRows. Instead of loading each one
individually, just load one and copy it for the rest; this avoids doing
the whole "search, read redir, find refcounted" code path for every
option.  Don't load data from OptionRow::AfterImportOptions.
2005-07-15 05:34:54 +00:00
Chris Danford 8998dfc589 add SetOneSharedSelectionIfPresent 2005-07-13 19:09:13 +00:00
Chris Danford 848d6c89e2 OptionRow: member name cleanup, add focus commands 2005-07-06 06:11:56 +00:00