Files
cappuccino/AppKit
David Richardson 5a1845957e AppKit: Implement CPOpenPanel for the browser
* CPItemProvider.j: Introduce CPItemProvider, modelled on NSItemProvider.
  - Register data representations keyed by MIME type, with wildcard matching.
  - Load representations asynchronously, completing inside a run loop pass.
  - Read browser File objects with FileReader.
  - Document remaining NSItemProvider compatibility gaps via TODO comments.

* Foundation.j: Import CPItemProvider.j.

* CPPlatformFilePanel.j: Introduce the DOM platform class that runs the browser's file dialog through a hidden file input.

* CPOpenPanel.j: Replace the NativeHost implementation with a browser implementation.
  - Implement -beginWithCompletionHandler: and -beginSheetModalForWindow:completionHandler:.
  - Add allowed file types, message, prompt, and an accessory view behind an Options button.
  - Validate chosen files through the window delegate's panel:validateURL:error:.
  - Add -itemProviders, and -URLs holding file names.
  - Raise an exception from -runModal.
  - Document remaining NSOpenPanel compatibility gaps via TODO comments.

* CPTextView.j: Insert images through CPOpenPanel and CPItemProvider, for both -insertImage: and paste.

* CPItemProviderTest.j, CPOpenPanelTest.j: Add unit tests covering registration, loading, type matching, panel results, and cancelled runs.
2026-11-02 14:52:41 -06:00
..
2026-10-25 17:46:10 +01:00
2020-08-30 09:47:21 +02:00
2013-01-23 15:48:55 +07:00
v02
2020-10-25 11:44:03 +01:00
2025-09-02 17:38:10 +03:00
2026-04-03 19:00:09 +02:00
2013-01-23 15:48:55 +07:00
2026-10-25 17:41:02 +01:00
2025-12-26 10:42:41 +01:00
2013-01-24 19:18:39 +08:00
2016-02-06 20:39:49 +01:00
2016-02-06 20:39:49 +01:00
2026-10-25 17:41:02 +01:00
2026-07-21 15:15:53 -06:00
2026-07-21 15:15:53 -06:00
2026-07-21 15:15:53 -06:00
2026-10-25 17:55:46 +01:00
2026-10-25 17:41:02 +01:00
2026-01-03 19:44:24 +01:00
2026-07-21 15:15:53 -06:00
2026-08-25 21:09:51 +02:00