Commit Graph

828 Commits

Author SHA1 Message Date
Joshua Bell 2415869008 Add Control Panel DA.
* Desktop pattern
* Double-click speed
* Joystick calibration
* Insertion point blink speed

Settings live in LCBANK1 at $FF80 and are persisted directly to DESKTOP2 when the DA closes. DeskTop itself is modified to pull values from there. IP blink routines are improved to not slow down when the mouse pointer is over the window.

Fixes #2, #31, #72
2019-07-30 21:22:28 -07:00
Joshua Bell daf6e87aec Rename the icon management logic in Aux 'Icon ToolKit' 2019-07-28 16:54:06 -07:00
Joshua Bell 24d318c274 Disasm: icon offset logic 2019-07-28 15:24:36 -07:00
Joshua Bell 13c1f6166a Move macros.inc into inc/ to tidy top level dir 2019-07-27 10:49:13 -07:00
Joshua Bell ff2f652c96 Move MGTK to mgtk/ dir to tidy up top level 2019-07-27 10:45:31 -07:00
Joshua Bell 157c6a3f0c Add MGTK Font file support for Preview.
Correct docs for some DeskTop icon APIs, and improve resilience of
some of the APIs to having atypical grafports selected when called.
2019-07-26 20:44:22 -07:00
Joshua Bell 6e96eae7ed DeskTop: Fix highlighting when dragging over icons. Fixes #163
The DeskTop library routines for handling icons switched GrafPorts
in a fragile way, which previous changes had broken. Updates to
the volume icon clipping code left the GrafPort used for icon
drawing clipped, and it was not restored correctly before subsequent
file icons were drawn.

Ensure the correct grafports are used everywhere, and reset them
when necessary. Further simplification is possible.
2019-07-23 21:07:53 -07:00
Joshua Bell e8a9add613 Correct icon clipping while dragging. Fixes #162
When dragging a selection over a desktop icon, the clipping rect of
the GrafPort used for drawing the outline would be changed. Broken
at some point, but probably only worked by accident. (Zero page fun?)

Introduce a dedicated grafport for drawing the outline.

Also, add some macros for pushorg/poporg
2019-07-22 21:14:20 -07:00
Joshua Bell 37091f842a Preview: Infer BIN at $4000 as image too 2019-07-20 10:06:01 -07:00
Joshua Bell a2659c7ae0 Fix clock inversion when desktop icon is selected. Fixes #161 2019-07-12 14:07:30 -07:00
Joshua Bell 46e413f3f1 Prevent crashes in Calculator/Eyes DA using ROM FP routines
During calls, MGTK uses the top half of the zero page to hold the
active grafport and local variables. It normally saves/restores the ZP
on each call so that the application's ZP state is preserved. Per
docs, the ZP1 call with param $00 can be used to disable this; MGTK
will write its state to the ZP and assume the ZP is not touched until
a subsequent ZP1 call with param $80, allowing higher performance.

DeskTop would normally run in this state ($00), except when DAs were
invoked since they could use ROM routines (etc) and expect the top
half of the ZP to be preserved during MGTK calls. But it did this with
a toggle ($00, $80, run the DA, then $00 again). Confusingly, the Calc
(and Eyes, c/o copy/pasta) DA would also attempt to get to a normal
state when running ($80, run, $00).

In rev 30532c31 I disabled DeskTop's toggling around DAs to fix an
issue in the Sort Directory DA (see #119), which might have changed
the overall behavior. The result is that on the IIc+ (and possibly
other hardware, but not Virtual II or Laser 128EX) the Calc and Eyes
DAs would crash.

This change disables use of the ZP1 by DeskTop and the DAs. This will
likely impair performance somewhat due to the save/restore overhead on
each call, but at least this gets us to a "known good state".

Fixes #157, #158
2019-07-11 15:50:20 -07:00
Joshua Bell 2d111d1771 Hold Apple key when double-clicking/File>Open to close parent. Resolves #9 2019-05-13 20:46:05 -07:00
Joshua Bell 39260141e8 DeskTop: Streamline File menu; repurpose Apple-W shortcut. Fixes #154 2019-05-09 21:43:51 -07:00
Joshua Bell 5efade0c6e DeskTop: Fix for icon redraw lockup #153 2019-05-09 20:56:36 -07:00
Joshua Bell dae33abc9a DeskTop: rename 'View > as Icons' menu item 2019-05-05 20:28:52 -07:00
Joshua Bell 0daa0f6184 DeskTop: Make type remapping data driven 2019-04-28 23:11:48 -07:00
Joshua Bell aa9194ad3f DeskTop: Improve window bounds calc for icon clipping. Fixes #152
The logic for computing window bounds started with the cliprect
returned by GetWinPort. But if the window content area is offscreen
that rect is invalid. Instead, use the Winfo's position/size records.

Also, significantly simplify the math used to account for borders,
title bars and scroll bars.
2019-04-25 21:25:58 -07:00
Joshua Bell 462d3e1914 DeskTop: Don't redraw hilited icons when obscured. Fixes #151 2019-04-24 23:45:18 -07:00
Joshua Bell e028076e0c Merge remote-tracking branch 'origin/disasm' 2019-04-24 23:44:08 -07:00
Joshua Bell f5b12036df disasm: handle_title_click 2019-04-24 23:41:53 -07:00
Joshua Bell 6a14ad7bf0 DeskTop: Check block count when treating BIN as FOT 2019-04-22 21:44:43 -07:00
Joshua Bell 1e162f3564 Make Apple-Delete shortcut for deleting file. Fixes #150 2019-04-14 19:38:47 -06:00
Joshua Bell 91d91d14c8 Use lookup table for hex digits 2019-04-12 10:27:55 -06:00
Joshua Bell f4114b3900 Merge remote-tracking branch 'origin/disasm' 2019-04-12 10:07:08 -06:00
Joshua Bell 4c875790b0 disasm: window icon/filerecord mapping 2019-04-12 10:03:07 -06:00
Joshua Bell bf3ab53af7 Disk Copy: Don't hard-code cross-overlay addresses. Fixes #147 2019-04-04 09:04:05 -07:00
Joshua Bell ba8c5a7383 DeskTop: Bump version/date 2019-04-03 19:35:38 -07:00
Joshua Bell 74f11c173d Fix opening folder/volume via double-clicking. Fixes #146
Broken by recent refactor; icon ptr needed to be saved after lookup.
2019-04-03 19:33:19 -07:00
Joshua Bell 1189a3a275 bump version/date 2019-04-02 21:21:07 -07:00
Joshua Bell f93b103687 Re-associate windows with dir icons. Fixes #144 2019-04-01 22:05:22 -07:00
Joshua Bell 9b2b361e90 Better handlng of recycled icons, dedupe code. 2019-04-01 20:37:01 -07:00
Joshua Bell 1abe9dec39 Merge remote-tracking branch 'origin/disasm' 2019-04-01 19:03:36 -07:00
Joshua Bell 7cf6f9406c disasm: window open logic 2019-04-01 18:58:01 -07:00
Joshua Bell b971f98a45 disasm: Disk Copy overlay flow 2019-03-30 16:57:37 -07:00
Joshua Bell 1db820679c Macro tidying: use param blocks; dedupe macros that differ only by order 2019-03-30 08:34:49 -07:00
Joshua Bell 05b1c02fe9 Hook reset to cleanly quit DeskTop back to ProDOS. Resolves #141
* Fails on Virtual II and KEGS/GSPort/GSPlus, as they fail to
  disable aux memory on reset
* Will fail within Disk Copy overlay
2019-03-29 18:52:52 -07:00
Joshua Bell 6d76fea638 DeskTop: Restore leading 0 for minutes 2019-03-26 21:28:22 -07:00
Joshua Bell 2f2c4ba26b DeskTop: tighten up clock code, remove extra space 2019-03-26 18:49:22 -07:00
Joshua Bell 546c264d5e DeskTop: Show day-of-week in menu bar clock. Fixes #142 2019-03-26 17:14:56 -07:00
Joshua Bell 6800e008c3 DeskTop: apple-backtick and apple-tab cycle windows. Fixes #143 2019-03-25 22:04:54 -07:00
Joshua Bell a9e77de75c doc updates 2019-03-17 19:17:28 -07:00
Joshua Bell c03c12956a DeskTop: Relocate removable device enumeration to init to save space 2019-03-17 19:10:06 -07:00
Joshua Bell b906cbb338 Remove unused 'System/Start' path check 2019-03-17 18:47:59 -07:00
Joshua Bell 36439b1219 Reset 'last menu', fixes DA menu restore after double-click. Fixes #139
Full-screen DAs/Previews assume they were launched from a menu and need to
restore the menu bar and hilite state. If launched via double-click there
is no hilite state to restore; handle this by setting the "last menu id"
to an unused value so the HiliteMenu call is a no-op.
2019-03-17 16:15:00 -07:00
Joshua Bell 2905a5c930 DeskTop: Avoid frequent STATUS calls on Laser 128. Maybe fixes #138
Also adjust double-click timing on Laser 128, assuming acceleration.
2019-03-17 15:34:18 -07:00
Joshua Bell b257e03fae DeskTop: improve volume icon spacing 2019-03-16 16:36:28 -07:00
Joshua Bell 6a88449189 DeskTop: bottom-align volume icons 2019-03-15 20:03:28 -07:00
Joshua Bell a79eba08d1 Add 'Screen Saver' DA, issue #27. Also adds DrawMenu to MGTK, fixes #136. 2019-03-11 19:44:07 -07:00
Joshua Bell 088ee11777 Image Preview: Add Minipix/Print Shop clip art support. Fixes #24 2019-03-08 18:53:37 -08:00
Joshua Bell 07efa542fa Merge remote-tracking branch 'origin/disasm' 2019-02-28 20:14:16 -08:00