45 Commits

Author SHA1 Message Date
Damiano Galassi
84c43deb75
MacGui: use UNUserNotificationCenter only on 10.15 and later
Try to avoid a crash on macOS 10.14
2025-03-11 08:03:00 +01:00
Damiano Galassi
f02f44a6a8
MacGui: try to work around a UNUserNotificationCenter issue on macOS 10.14 2025-03-10 08:22:25 +01:00
Damiano Galassi
861d2164f4
MacGui: new toolbar style using SF Symbol on macOS 11 and later. Improved toolbar buttons behaviour in text mode. 2024-03-02 08:47:58 +01:00
Damiano Galassi
757efe9123
MacGui: recover when the xpc service crashes. 2019-08-11 09:58:32 +02:00
Damiano Galassi
97734fff76
MacGui: refactor the queue and implement part of the new queue ui. 2019-07-19 21:17:27 +02:00
Damiano Galassi
c762b2c0ec
MacGui: set the minimum deployment target to 10.10. Remove Growl and use macOS standard notifications. Remove deprecated API usage and code that doesn't compile anymore (QTKit). 2018-06-08 16:59:25 +02:00
Damiano Galassi
89c0a25d54 MacGui: annotate the type of some arrays, and check the count of the input jobs in HBQueueController addJobsFromArray:, so we don't add an empty undo command. 2015-10-28 08:15:52 +01:00
Damiano Galassi
333a81d499 MacGui: improved queue with undo/redo support for adding/removing jobs, and added a icon for failed encode. 2015-10-19 17:57:49 +02:00
ritsuka
d4a4a3ccd6 MacGui: second part of the previous commit
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7392 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-08-06 09:48:39 +00:00
ritsuka
be9ac805c8 MacGui: various queue improvements, including:
- multiple items drag & drop
- "reset job" in contextual menu item to reset the job state
- a toolbar item to select the action to perform when the queue is done
- useless animations.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7358 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-07-22 07:46:07 +00:00
ritsuka
2837048a59 MacGui: add nullability annotations to the headers and use weak where is possible.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7244 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-05-30 07:17:22 +00:00
ritsuka
7b402b36a8 MacGui: Remove the "Reload queue" alert. The queue is always reloaded and the queue window is shown if there are pending jobs.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7113 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-04-22 16:58:07 +00:00
ritsuka
48a9e54687 MacGui: convert the mac gui to Objective-C ARC.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6996 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-03-17 13:56:21 +00:00
ritsuka
214fed29cd MacGui: refactor the stderr/stdout redirect code to be more modular.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6927 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-02-20 07:59:38 +00:00
ritsuka
dfa1f8dd4b MacGui: move the application delegate to its own class. Removed the "Open Source (Title Specific)" menu item, now integrated in the standard open panel.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6784 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-01-22 10:30:26 +00:00
ritsuka
184584ac80 MacGui: rename cancel: to cancelRip: so it won't be automatically called when the esc key is pressed.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6778 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-01-20 08:05:16 +00:00
ritsuka
f69f4e15cf MacGui: moved the queue code from HBController to HBQueueController, reworked the way the queue synchronise itself between multiple instances to be more resilient (hopefully). Modified HBCore to take callback blocks instead of notifications.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6770 b64f7644-9d1e-0410-96f1-a4d463321fa5
2015-01-19 08:48:18 +00:00
ritsuka
df8b2ff3e1 MacGui: change the queue to work with serialized HBJob objects, remove the NSDictionary job representation and the duplicate prepareJob method. Implement NSCopying protocol in HBJob.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6655 b64f7644-9d1e-0410-96f1-a4d463321fa5
2014-12-27 10:46:04 +00:00
ritsuka
3ddf9cdc8a MacGui: moved the HBQueueOutlineView class to its own file.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6539 b64f7644-9d1e-0410-96f1-a4d463321fa5
2014-11-23 12:56:03 +00:00
ritsuka
31f0491273 MacGui: general clean up of HBQueueController: removed unused UI elements and code, moved the toolbar to the xib, update the obj-c syntax.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6306 b64f7644-9d1e-0410-96f1-a4d463321fa5
2014-08-18 06:22:02 +00:00
ritsuka
edc929027e MacGUI: fixed a number of leaks/null-deferences/dead-code found by clang static analyzer.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5838 b64f7644-9d1e-0410-96f1-a4d463321fa5
2013-10-15 11:36:51 +00:00
Rodeo
173b4f7046 MacGui: fix compil<tion with clang.
Implementing a protocol is not enough, we need to actually tell the compiler that we are doing it.


git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5788 b64f7644-9d1e-0410-96f1-a4d463321fa5
2013-09-20 15:35:51 +00:00
dynaflash
33532ab4f7 MacGui: Fix how we get the current instances pid number since NSRunningApplication is a 10.6 only api and therefore breaks 10.5 compatibility (which also borked the nightly build).
- Many thanks to ritsuka for pointing this out.
- Also adds ability to get the full path to each running instance if we need it in the future.
- Note: Adds additional logging to hbInstances which can be removed when we see fit. But for now imho could be useful since we are early in multi-instance queue encoding.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3450 b64f7644-9d1e-0410-96f1-a4d463321fa5
2010-07-19 17:02:43 +00:00
dynaflash
3c92cad4fe MacGui: Initial implementation of new queue sync code which allows multi-instance encoding.
This allows more than one instances of HandBrake.app to run off of the same queue file.
In the case of multi-instance use these changes occur in the queue window:
- The delete icon for a given queue item does not exist in the queue window if another instance is doing the encoding.
- The encoding icon does not spin if another instance is doing the encoding.
- As before if the queue window is for the instance doing the encoding on that item it will be animated and "spins".
- The queue window  status readout now also includes the output file name for the file being encoded for that instance.

Known bugs: 
- Drag and Drop queue reordering is somwehat borked. Doesn't corrupt queue but can not allow a drop in some instances.
- I have tested this over 20 multi instance encodes and not once had an issue, but anytime more than one instance is writing to the same external file anything can happen. Beware!
- The session activity log will of course be full of activity log info from all instances in a multi instance scenario. Individual encode logs are unaffected.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3443 b64f7644-9d1e-0410-96f1-a4d463321fa5
2010-07-17 19:15:38 +00:00
dynaflash
56fef9aafb MacGui: Queued item editing initial implementation.
- Sends a chosen queued item back to the main window for reload ( and rescan ) via contextual menu (right click)
- Deletes queued item from queue after being reloaded to main window ( after editing or whatever, send back to queue via Add To Queue Button same as a new source).
- New queue window contextual menu also includes delete and show options previously only available via separate icons.
- Note: Needs testing particularly in the subtitle area, which is not to say there aren't other bugs.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3080 b64f7644-9d1e-0410-96f1-a4d463321fa5
2010-01-21 18:58:17 +00:00
dynaflash
007dd35a0c MacGui: Queue - Fix drag'n drop so that when dragging over an item, it doesn't auto expand.
- Also fix some really hosed up formatting
- Remove the unused moveObjectsInQueueArray method from HBQueueController ( we moved that to Controller.mm back in 1703 but left it "just in case").

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1778 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-09-26 18:57:38 +00:00
dynaflash
441c3d7257 MacGui: Add encoding status readout to the queue window
- is fed info from controller.mm instead of the old setup which had another NSTimer polling libhb just for the queue.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1742 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-09-22 14:44:13 +00:00
dynaflash
ab154ca555 MacGui: Resilient Queue: Initial Implementation
- Completely overhauls how encodes are setup by the MacGui
- All encodes are now stored in an NSMutableArray (QueueFileArray) and saved in a plist (~/Library/Application Support/HandBrake/Queue.plist) 
- A separate instance of libhb (fQueueEncodeLibhb) is used for queue processing (includes single encodes)
- fHandle still takes care of all user intiated scans and encode parameters
- libhb now only stores multiple passes for a single encode instead of storing the entire queue
- If HB crashes, or if you stop encoding while there are still pending encodes in your queue, upon next launch you will be prompted to reload the previous queue from the Queue.plist
- Removed the current encoding information at the top of the queue window to make room for a larger list as I thought it to be redundant
- The queue list is now re-arrangeable via drag-n-drop (pending encodes only)
- Known issues and bugs:
-- If you delete a previously cancelled encode then try to restart with a new encode, nothing happens. Throw off the sync of the currently encoding job.
-- Probably alot more since its a total overhaul of how the MacGui has handled encoding since titer originally wrote it :)   

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1703 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-09-16 20:57:13 +00:00
ritsuka
c8ed1a0c15 MacGui: Some small enhancements and clean ups in HBQueueController
- Removed white spaces and hard tabs.
		- Changed all the enumerators to use the new fast enumerators available in objective-c 2.
		- Changed intValue to integerValue.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1613 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-08-07 17:26:25 +00:00
dynaflash
cd88f15146 MacGui: convert HBQueueController to be a subclass of NSWindowController - kudos again to blindjimmy
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1515 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-06-17 12:40:17 +00:00
dynaflash
b856292606 MacGui: replace handbrake.m0k.org references with handbrake.fr in the entire macosx/ directory
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1419 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-04-15 17:08:31 +00:00
ritsuka
9d9cb0efcc MacGUI: Forgot a file in my previous commit.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1394 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-04-08 13:02:43 +00:00
dynaflash
336bb4ae45 MacGui: Implement per track audio settings.
- Expands the number of audio tracks the macgui can encode to 4.
- Everything except drc is now set on a per track basis
- Be Gone self limiting "Codecs" PopUp !
- Can now use any audio codecs that the container will support in the same encode
- The previous "AAC + AC3" bizarre hybrid is now deprecated and you simply set them up per track
- Implement full audio list readout in the queue, tracks are now show one per line in a list like fashion
- Queue is no longer hard coded for just two tracks.
- Preset code updated to regress to handle previous presets that utilized the codecs popup to determine audio scheme to use
- Preset code now handles everything except language selection.
- The Format, Video Encoder and Audio codes are all now stored in the appropriate NSPopUp tags for very easy retrieval.
- Crazy format, codecs struct is now gone as we get that from the tags.
- AC3 Passthru properly shows the input bitrate and 48 khz samplerate in the appropriate popups
- Added Theora video encoder to OGM container
- Added libtheora to the libhb dylib 
- NOTE: The check against trying to use AC3 Passthru on a DTS track is broken on the encoder popup.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1385 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-04-07 05:02:18 +00:00
saintdev
e89137df81 MacGUI: Update to use the new audio layout.
This only updates the current interface, nothing new added.


git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1367 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-04-01 21:29:38 +00:00
dynaflash
0ec912f5fd MacGui: Adds Loose Anamorphic information to the queue display
- patch by travistex

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1238 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-01-29 16:11:47 +00:00
dynaflash
8520e5c0c5 MacGui: Warn of duplicate output filenames when adding to the queue.
- Thanks travistex

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1192 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-01-14 13:58:19 +00:00
dynaflash
7ce30b2e99 MacGui: Add preset name used (or custom) to the queue and activity log
- Courtesy of travistex
- Uses "Custom" if the settings do not reflect a preset
- Changed some names of functions in HBQueueController and added some comments
- The main controller now notifies the queue controller whenever jobs are added to libhb. This allows the queue to find out about such jobs without having to query libhb's job list periodically.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1179 b64f7644-9d1e-0410-96f1-a4d463321fa5
2008-01-09 05:45:36 +00:00
dynaflash
4a53d572a8 MacGui: Queue Update - thanks travistex
- The primary change is that HBJob now copies the relevant fields out of hb_job_s that it needs. It no longer keeps a pointer reference to libhb's job.
- The only time the queue looks at libhb's jobs is when scanning the job list in order to build of the GUI queue display.
- Removed all uses of hb_current_job().
- Canceled jobs now stay listed in the queue, with a canceled icon.



git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1130 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-12-17 16:25:38 +00:00
dynaflash
7045d521d4 MacGui: Queue Enhancements courtesy of travistex
- Encodes now stick around in the queue's displayed after they have been completed. They are marked with a check mark icon.
- The "active" encode is shown with a chasing arrows icon.
- Completed encodes have a spotlight icon by them to allow you to show in finder
- Support for reordering encodes in the queue via drag and drop. Currently #define'd out because there's currently no easy way to reorder hblib's job list. But some day maybe...

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1017 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-10-09 15:15:16 +00:00
dynaflash
2f4097f0af MacGui: Queue update adds auto wrap to detail lines so that detail does not get truncated.
- Also deletes some unused icons from the xcode project as well as from the svn including some from rev 984

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@985 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-24 15:22:24 +00:00
dynaflash
a07f5a552d MacGui: Queue improvements from travistex
- Detail info for each pass has been cleaned up. Each pass only displays info relevant to its pass. No line wrapping yet. :-(
- In the gui, "subtitle scan" changed to "in-depth scan". Is that what we want to call it?
- Fixed cases where single pass jobs were identified incorrectly in the queue.
- Removed incessant updating of the queue gui. The gui now only updates when something changes.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@968 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-17 14:46:36 +00:00
dynaflash
f45d2e22f0 MacGui: New Queue Enhancements courtesy of travistex
- New hierarchical queue view.
- New Start/Cancel and Pause/Resume buttons in Queue toolbar to match those in the main window.
- When canceling a job, you now have the option to delete all pending jobs.
- This one is the real deal! 

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@963 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-14 04:42:46 +00:00
dynaflash
35c3cb421a MacGui: New queue enhancements
- clean up work related to starting and stopping of jobs to make sure the behavior is the same in both the queue window and the main window
- No longer adds jobs to queue when you've hit Start but then canceled the overwrite warning.
- Added overwrite alert when doing an Add to Queue. Was only happening previously when you did a Start.
- Stopping a job from either the Queue window or the Main window now goes through the same code path and so the behavior will be identical.
- In the main window, the Start button now changes to Start Queue once you've added things to the queue. This helps clear up any ambiguity about what that button will do
- Cancel button now named Stop. Recommended by BradleyS and/or hawkman I think because this button no longer cancels everything in the queue, just the current job. Wording in the stop warning dialog has been improved (mentions job title).
- The "Show Alert When Done" options now work when you have started the queue from the Queue window.
- Uses the term "passes" in main window
- Added unique icons for each pass type.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@949 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-11 15:03:01 +00:00
dynaflash
ccf90bfd91 MacGui: Queue Improvements from travistex
- Add view selection widget to choose "encode by encode" or "pass by pass" view
- Add "Show Detail" button to toggle detailed view on/off
- Removed #define JOB_GROUPS. You can now control this in the UI and show either "encodes" or "passes".
- Revamped the progress strings to give you exact progress.
- New terminology (encodes and passes)
- New toolbar in queue window (not complete, icons need work)
- New files, added to project:
     Encodes.png
     EncodesPressed.png
     Info.png
     JobPassLarge.png
     JobPassSmall.png
     Passes.png
     PassesPressed.png

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@931 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-07 13:40:40 +00:00
dynaflash
5d4117bccd MacGui: New Active Queue implementation courtesy of travistex
- Thanks travistex!
- queue is now in a separate window
- queue currently shows jobs grouped together as one encode, which is configurable
- queue now shows currently encoding job, which is independently cancellable without losing the rest of the queue.
- can start and pause encoding in the queue window
- queue uses its own nib
- progress status needs work
- This has a way to go, but needed to get checked in as it changes the current xcode project structure.

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@925 b64f7644-9d1e-0410-96f1-a4d463321fa5
2007-09-05 20:01:14 +00:00