Files
cappuccino/Tests/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
..
2013-01-20 19:10:41 +00:00
2011-04-23 15:50:32 +02:00
2011-04-25 14:12:52 +02:00
2026-02-28 18:26:47 +01:00
2025-07-05 12:33:21 +02:00
2025-07-05 12:35:43 +02:00
2025-07-05 09:04:26 +02:00
2025-09-04 11:54:06 +03:00
2026-02-08 16:00:58 +01:00
2015-10-23 10:19:14 +02:00
2026-08-25 20:39:34 +02:00
2025-06-22 21:52:57 +02:00