Browse Source

Added EZAudio framework, already listing available audio input devices and storing selection. Visualization still missing.

Thomas Buck 9 years ago
parent
commit
2c1b62156b

+ 62
- 2
CaseLights.xcodeproj/project.pbxproj View File

7
 	objects = {
7
 	objects = {
8
 
8
 
9
 /* Begin PBXBuildFile section */
9
 /* Begin PBXBuildFile section */
10
+		E9101B871C36B11500720A6E /* EZAudioOSX.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = E9101B831C36B0C100720A6E /* EZAudioOSX.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
11
+		E9101B881C36B4B100720A6E /* EZAudioOSX.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E9101B831C36B0C100720A6E /* EZAudioOSX.framework */; };
10
 		E9109B111C2AACF400726111 /* SystemInfoKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */; };
12
 		E9109B111C2AACF400726111 /* SystemInfoKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */; };
11
 		E9109B151C2AAEFD00726111 /* SystemInfoKit.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
13
 		E9109B151C2AAEFD00726111 /* SystemInfoKit.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
12
 		E9109B191C2AAFE100726111 /* GPUStats.m in Sources */ = {isa = PBXBuildFile; fileRef = E9109B181C2AAFE100726111 /* GPUStats.m */; };
14
 		E9109B191C2AAFE100726111 /* GPUStats.m in Sources */ = {isa = PBXBuildFile; fileRef = E9109B181C2AAFE100726111 /* GPUStats.m */; };
19
 /* End PBXBuildFile section */
21
 /* End PBXBuildFile section */
20
 
22
 
21
 /* Begin PBXContainerItemProxy section */
23
 /* Begin PBXContainerItemProxy section */
24
+		E9101B801C36B0C100720A6E /* PBXContainerItemProxy */ = {
25
+			isa = PBXContainerItemProxy;
26
+			containerPortal = E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */;
27
+			proxyType = 2;
28
+			remoteGlobalIDString = 469F4CF31B749F7800666A46;
29
+			remoteInfo = EZAudioiOS;
30
+		};
31
+		E9101B821C36B0C100720A6E /* PBXContainerItemProxy */ = {
32
+			isa = PBXContainerItemProxy;
33
+			containerPortal = E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */;
34
+			proxyType = 2;
35
+			remoteGlobalIDString = 8A5A4B9C1BBBDCB200A8A048;
36
+			remoteInfo = EZAudioOSX;
37
+		};
38
+		E9101B851C36B10C00720A6E /* PBXContainerItemProxy */ = {
39
+			isa = PBXContainerItemProxy;
40
+			containerPortal = E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */;
41
+			proxyType = 1;
42
+			remoteGlobalIDString = 8A5A4B9B1BBBDCB200A8A048;
43
+			remoteInfo = EZAudioOSX;
44
+		};
22
 		E9109B0A1C2AAC1B00726111 /* PBXContainerItemProxy */ = {
45
 		E9109B0A1C2AAC1B00726111 /* PBXContainerItemProxy */ = {
23
 			isa = PBXContainerItemProxy;
46
 			isa = PBXContainerItemProxy;
24
 			containerPortal = E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */;
47
 			containerPortal = E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */;
49
 			dstPath = "";
72
 			dstPath = "";
50
 			dstSubfolderSpec = 10;
73
 			dstSubfolderSpec = 10;
51
 			files = (
74
 			files = (
75
+				E9101B871C36B11500720A6E /* EZAudioOSX.framework in CopyFiles */,
52
 				E9109B151C2AAEFD00726111 /* SystemInfoKit.framework in CopyFiles */,
76
 				E9109B151C2AAEFD00726111 /* SystemInfoKit.framework in CopyFiles */,
53
 			);
77
 			);
54
 			runOnlyForDeploymentPostprocessing = 0;
78
 			runOnlyForDeploymentPostprocessing = 0;
56
 /* End PBXCopyFilesBuildPhase section */
80
 /* End PBXCopyFilesBuildPhase section */
57
 
81
 
58
 /* Begin PBXFileReference section */
82
 /* Begin PBXFileReference section */
83
+		E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = EZAudio.xcodeproj; path = EZAudio/EZAudio.xcodeproj; sourceTree = "<group>"; };
59
 		E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = SystemInfoKit.xcodeproj; path = JSystemInfoKit/SystemInfoKit.xcodeproj; sourceTree = "<group>"; };
84
 		E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = SystemInfoKit.xcodeproj; path = JSystemInfoKit/SystemInfoKit.xcodeproj; sourceTree = "<group>"; };
60
 		E9109B171C2AAFE100726111 /* GPUStats.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GPUStats.h; path = CaseLights/GPUStats.h; sourceTree = "<group>"; };
85
 		E9109B171C2AAFE100726111 /* GPUStats.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GPUStats.h; path = CaseLights/GPUStats.h; sourceTree = "<group>"; };
61
 		E9109B181C2AAFE100726111 /* GPUStats.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GPUStats.m; path = CaseLights/GPUStats.m; sourceTree = "<group>"; };
86
 		E9109B181C2AAFE100726111 /* GPUStats.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GPUStats.m; path = CaseLights/GPUStats.m; sourceTree = "<group>"; };
78
 			buildActionMask = 2147483647;
103
 			buildActionMask = 2147483647;
79
 			files = (
104
 			files = (
80
 				E9109B111C2AACF400726111 /* SystemInfoKit.framework in Frameworks */,
105
 				E9109B111C2AACF400726111 /* SystemInfoKit.framework in Frameworks */,
106
+				E9101B881C36B4B100720A6E /* EZAudioOSX.framework in Frameworks */,
81
 			);
107
 			);
82
 			runOnlyForDeploymentPostprocessing = 0;
108
 			runOnlyForDeploymentPostprocessing = 0;
83
 		};
109
 		};
84
 /* End PBXFrameworksBuildPhase section */
110
 /* End PBXFrameworksBuildPhase section */
85
 
111
 
86
 /* Begin PBXGroup section */
112
 /* Begin PBXGroup section */
113
+		E9101B7C1C36B0C100720A6E /* Products */ = {
114
+			isa = PBXGroup;
115
+			children = (
116
+				E9101B811C36B0C100720A6E /* EZAudioiOS.framework */,
117
+				E9101B831C36B0C100720A6E /* EZAudioOSX.framework */,
118
+			);
119
+			name = Products;
120
+			sourceTree = "<group>";
121
+		};
87
 		E9109B061C2AAC1B00726111 /* Products */ = {
122
 		E9109B061C2AAC1B00726111 /* Products */ = {
88
 			isa = PBXGroup;
123
 			isa = PBXGroup;
89
 			children = (
124
 			children = (
110
 		E9F13DF51C28B3D3004C6B95 = {
145
 		E9F13DF51C28B3D3004C6B95 = {
111
 			isa = PBXGroup;
146
 			isa = PBXGroup;
112
 			children = (
147
 			children = (
148
+				E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */,
113
 				E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */,
149
 				E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */,
114
 				E9F13E001C28B3D3004C6B95 /* CaseLights */,
150
 				E9F13E001C28B3D3004C6B95 /* CaseLights */,
115
 				E9F13DFF1C28B3D3004C6B95 /* Products */,
151
 				E9F13DFF1C28B3D3004C6B95 /* Products */,
162
 			buildRules = (
198
 			buildRules = (
163
 			);
199
 			);
164
 			dependencies = (
200
 			dependencies = (
201
+				E9101B861C36B10C00720A6E /* PBXTargetDependency */,
165
 				E9109B131C2AAD2E00726111 /* PBXTargetDependency */,
202
 				E9109B131C2AAD2E00726111 /* PBXTargetDependency */,
166
 			);
203
 			);
167
 			name = CaseLights;
204
 			name = CaseLights;
196
 			projectDirPath = "";
233
 			projectDirPath = "";
197
 			projectReferences = (
234
 			projectReferences = (
198
 				{
235
 				{
236
+					ProductGroup = E9101B7C1C36B0C100720A6E /* Products */;
237
+					ProjectRef = E9101B7B1C36B0C100720A6E /* EZAudio.xcodeproj */;
238
+				},
239
+				{
199
 					ProductGroup = E9109B061C2AAC1B00726111 /* Products */;
240
 					ProductGroup = E9109B061C2AAC1B00726111 /* Products */;
200
 					ProjectRef = E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */;
241
 					ProjectRef = E9109B051C2AAC1B00726111 /* SystemInfoKit.xcodeproj */;
201
 				},
242
 				},
208
 /* End PBXProject section */
249
 /* End PBXProject section */
209
 
250
 
210
 /* Begin PBXReferenceProxy section */
251
 /* Begin PBXReferenceProxy section */
252
+		E9101B811C36B0C100720A6E /* EZAudioiOS.framework */ = {
253
+			isa = PBXReferenceProxy;
254
+			fileType = wrapper.framework;
255
+			path = EZAudioiOS.framework;
256
+			remoteRef = E9101B801C36B0C100720A6E /* PBXContainerItemProxy */;
257
+			sourceTree = BUILT_PRODUCTS_DIR;
258
+		};
259
+		E9101B831C36B0C100720A6E /* EZAudioOSX.framework */ = {
260
+			isa = PBXReferenceProxy;
261
+			fileType = wrapper.framework;
262
+			path = EZAudioOSX.framework;
263
+			remoteRef = E9101B821C36B0C100720A6E /* PBXContainerItemProxy */;
264
+			sourceTree = BUILT_PRODUCTS_DIR;
265
+		};
211
 		E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */ = {
266
 		E9109B0B1C2AAC1B00726111 /* SystemInfoKit.framework */ = {
212
 			isa = PBXReferenceProxy;
267
 			isa = PBXReferenceProxy;
213
 			fileType = wrapper.framework;
268
 			fileType = wrapper.framework;
269
 /* End PBXSourcesBuildPhase section */
324
 /* End PBXSourcesBuildPhase section */
270
 
325
 
271
 /* Begin PBXTargetDependency section */
326
 /* Begin PBXTargetDependency section */
327
+		E9101B861C36B10C00720A6E /* PBXTargetDependency */ = {
328
+			isa = PBXTargetDependency;
329
+			name = EZAudioOSX;
330
+			targetProxy = E9101B851C36B10C00720A6E /* PBXContainerItemProxy */;
331
+		};
272
 		E9109B131C2AAD2E00726111 /* PBXTargetDependency */ = {
332
 		E9109B131C2AAD2E00726111 /* PBXTargetDependency */ = {
273
 			isa = PBXTargetDependency;
333
 			isa = PBXTargetDependency;
274
 			name = SystemInfoKit;
334
 			name = SystemInfoKit;
377
 				MACOSX_DEPLOYMENT_TARGET = 10.8;
437
 				MACOSX_DEPLOYMENT_TARGET = 10.8;
378
 				PRODUCT_BUNDLE_IDENTIFIER = de.xythobuz.CaseLights;
438
 				PRODUCT_BUNDLE_IDENTIFIER = de.xythobuz.CaseLights;
379
 				PRODUCT_NAME = "$(TARGET_NAME)";
439
 				PRODUCT_NAME = "$(TARGET_NAME)";
380
-				USER_HEADER_SEARCH_PATHS = "JSystemInfoKit/**";
440
+				USER_HEADER_SEARCH_PATHS = "JSystemInfoKit/** EZAudio/EZAudio/**";
381
 			};
441
 			};
382
 			name = Debug;
442
 			name = Debug;
383
 		};
443
 		};
392
 				MACOSX_DEPLOYMENT_TARGET = 10.8;
452
 				MACOSX_DEPLOYMENT_TARGET = 10.8;
393
 				PRODUCT_BUNDLE_IDENTIFIER = de.xythobuz.CaseLights;
453
 				PRODUCT_BUNDLE_IDENTIFIER = de.xythobuz.CaseLights;
394
 				PRODUCT_NAME = "$(TARGET_NAME)";
454
 				PRODUCT_NAME = "$(TARGET_NAME)";
395
-				USER_HEADER_SEARCH_PATHS = "JSystemInfoKit/**";
455
+				USER_HEADER_SEARCH_PATHS = "JSystemInfoKit/** EZAudio/EZAudio/**";
396
 			};
456
 			};
397
 			name = Release;
457
 			name = Release;
398
 		};
458
 		};

+ 6
- 1
CaseLights/AppDelegate.h View File

8
 
8
 
9
 #import <Cocoa/Cocoa.h>
9
 #import <Cocoa/Cocoa.h>
10
 
10
 
11
+#import "EZAudio.h"
12
+#import "SystemInfoKit/SystemInfoKit.h"
13
+
11
 @class Serial;
14
 @class Serial;
12
 
15
 
13
-@interface AppDelegate : NSObject <NSApplicationDelegate>
16
+@interface AppDelegate : NSObject <NSApplicationDelegate, EZMicrophoneDelegate>
14
 
17
 
15
 @property (weak) IBOutlet NSMenu *statusMenu;
18
 @property (weak) IBOutlet NSMenu *statusMenu;
16
 @property (weak) IBOutlet NSApplication *application;
19
 @property (weak) IBOutlet NSApplication *application;
20
 @property (weak) IBOutlet NSMenu *menuVisualizations;
23
 @property (weak) IBOutlet NSMenu *menuVisualizations;
21
 @property (weak) IBOutlet NSMenuItem *menuItemDisplays;
24
 @property (weak) IBOutlet NSMenuItem *menuItemDisplays;
22
 @property (weak) IBOutlet NSMenu *menuDisplays;
25
 @property (weak) IBOutlet NSMenu *menuDisplays;
26
+@property (weak) IBOutlet NSMenuItem *menuItemAudio;
27
+@property (weak) IBOutlet NSMenu *menuAudio;
23
 @property (weak) IBOutlet NSMenu *menuPorts;
28
 @property (weak) IBOutlet NSMenu *menuPorts;
24
 
29
 
25
 @property (weak) IBOutlet NSMenuItem *buttonOff;
30
 @property (weak) IBOutlet NSMenuItem *buttonOff;

+ 201
- 18
CaseLights/AppDelegate.m View File

11
 #import "GPUStats.h"
11
 #import "GPUStats.h"
12
 #import "Screenshot.h"
12
 #import "Screenshot.h"
13
 
13
 
14
-#import "SystemInfoKit/SystemInfoKit.h"
15
-
14
+// These are the values stored persistently in the preferences
16
 #define PREF_SERIAL_PORT @"SerialPort"
15
 #define PREF_SERIAL_PORT @"SerialPort"
17
 #define PREF_LIGHTS_STATE @"LightState"
16
 #define PREF_LIGHTS_STATE @"LightState"
17
+// LED Mode contains the last selected mode as menu item text
18
 #define PREF_LED_MODE @"LEDMode"
18
 #define PREF_LED_MODE @"LEDMode"
19
 #define PREF_BRIGHTNESS @"Brightness"
19
 #define PREF_BRIGHTNESS @"Brightness"
20
 #define PREF_COLOR @"ManualColor"
20
 #define PREF_COLOR @"ManualColor"
29
 #define TEXT_RGB_FADE @"RGB Fade"
29
 #define TEXT_RGB_FADE @"RGB Fade"
30
 #define TEXT_HSV_FADE @"HSV Fade"
30
 #define TEXT_HSV_FADE @"HSV Fade"
31
 #define TEXT_RANDOM @"Random"
31
 #define TEXT_RANDOM @"Random"
32
+#define TEXT_TEMPLATE_AUDIO @"AudioDevice_%@"
32
 
33
 
34
+// SMC keys are checked for existence and used for reading
33
 #define KEY_CPU_TEMPERATURE @"TC0D"
35
 #define KEY_CPU_TEMPERATURE @"TC0D"
34
 #define KEY_GPU_TEMPERATURE @"TG0D"
36
 #define KEY_GPU_TEMPERATURE @"TG0D"
35
 
37
 
53
 #define AVERAGE_COLOR_PERFORMANCE_INC 10
55
 #define AVERAGE_COLOR_PERFORMANCE_INC 10
54
 #define DISPLAY_DELAY 0.1
56
 #define DISPLAY_DELAY 0.1
55
 
57
 
58
+// Used to identify selected menu items
59
+// displays are all tags >= 0
60
+#define MENU_ITEM_TAG_NOTHING -1
61
+#define MENU_ITEM_TAG_AUDIO -2
62
+
56
 @interface AppDelegate ()
63
 @interface AppDelegate ()
57
 
64
 
58
 @property (strong) NSStatusItem *statusItem;
65
 @property (strong) NSStatusItem *statusItem;
61
 @property (strong) NSTimer *animation;
68
 @property (strong) NSTimer *animation;
62
 @property (strong) Serial *serial;
69
 @property (strong) Serial *serial;
63
 @property (strong) NSMenuItem *lastLEDMode;
70
 @property (strong) NSMenuItem *lastLEDMode;
71
+@property (strong) EZMicrophone *microphone;
64
 
72
 
65
 @end
73
 @end
66
 
74
 
69
 @synthesize statusMenu, application;
77
 @synthesize statusMenu, application;
70
 @synthesize menuColors, menuAnimations, menuVisualizations, menuPorts;
78
 @synthesize menuColors, menuAnimations, menuVisualizations, menuPorts;
71
 @synthesize menuItemDisplays, menuDisplays;
79
 @synthesize menuItemDisplays, menuDisplays;
80
+@synthesize menuItemAudio, menuAudio;
72
 @synthesize buttonOff, buttonLights;
81
 @synthesize buttonOff, buttonLights;
73
 @synthesize brightnessItem, brightnessSlider, brightnessLabel;
82
 @synthesize brightnessItem, brightnessSlider, brightnessLabel;
74
 @synthesize statusItem, statusImage;
83
 @synthesize statusItem, statusImage;
75
 @synthesize staticColors, animation;
84
 @synthesize staticColors, animation;
76
-@synthesize serial, lastLEDMode;
85
+@synthesize serial, lastLEDMode, microphone;
77
 @synthesize menuItemColor;
86
 @synthesize menuItemColor;
78
 
87
 
79
 - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
88
 - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
82
     serial = [[Serial alloc] init];
91
     serial = [[Serial alloc] init];
83
     lastLEDMode = nil;
92
     lastLEDMode = nil;
84
     animation = nil;
93
     animation = nil;
94
+    microphone = nil;
85
     
95
     
86
     // Prepare status bar menu
96
     // Prepare status bar menu
87
     statusImage = [NSImage imageNamed:@"MenuIcon"];
97
     statusImage = [NSImage imageNamed:@"MenuIcon"];
120
         for (int i = 0; i < [ports count]; i++) {
130
         for (int i = 0; i < [ports count]; i++) {
121
             // Add Menu Item for this port
131
             // Add Menu Item for this port
122
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[ports objectAtIndex:i] action:@selector(selectedSerialPort:) keyEquivalent:@""];
132
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[ports objectAtIndex:i] action:@selector(selectedSerialPort:) keyEquivalent:@""];
123
-            [item setTag:-1];
133
+            [item setTag:MENU_ITEM_TAG_NOTHING];
124
             [menuPorts addItem:item];
134
             [menuPorts addItem:item];
125
             
135
             
126
             // Set Enabled if it was used the last time
136
             // Set Enabled if it was used the last time
155
                     nil];
165
                     nil];
156
     for (NSString *key in [staticColors allKeys]) {
166
     for (NSString *key in [staticColors allKeys]) {
157
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:key action:@selector(selectedVisualization:) keyEquivalent:@""];
167
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:key action:@selector(selectedVisualization:) keyEquivalent:@""];
158
-        [item setTag:-1];
168
+        [item setTag:MENU_ITEM_TAG_NOTHING];
159
         if ([key isEqualToString:lastMode]) {
169
         if ([key isEqualToString:lastMode]) {
160
             [self selectedVisualization:item];
170
             [self selectedVisualization:item];
161
         }
171
         }
169
         }
179
         }
170
         [menuItemColor setState:NSOnState];
180
         [menuItemColor setState:NSOnState];
171
     }
181
     }
172
-    [menuItemColor setTag:-1];
182
+    [menuItemColor setTag:MENU_ITEM_TAG_NOTHING];
173
     [menuColors addItem:menuItemColor];
183
     [menuColors addItem:menuItemColor];
174
     
184
     
175
     // Prepare animations menu
185
     // Prepare animations menu
180
                                  nil];
190
                                  nil];
181
     for (NSString *key in animationStrings) {
191
     for (NSString *key in animationStrings) {
182
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:key action:@selector(selectedVisualization:) keyEquivalent:@""];
192
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:key action:@selector(selectedVisualization:) keyEquivalent:@""];
183
-        [item setTag:-1];
193
+        [item setTag:MENU_ITEM_TAG_NOTHING];
184
         if ([key isEqualToString:lastMode]) {
194
         if ([key isEqualToString:lastMode]) {
185
             [self selectedVisualization:item];
195
             [self selectedVisualization:item];
186
         }
196
         }
189
     
199
     
190
     // Add CPU Usage menu item
200
     // Add CPU Usage menu item
191
     NSMenuItem *cpuUsageItem = [[NSMenuItem alloc] initWithTitle:TEXT_CPU_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
201
     NSMenuItem *cpuUsageItem = [[NSMenuItem alloc] initWithTitle:TEXT_CPU_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
192
-    [cpuUsageItem setTag:-1];
202
+    [cpuUsageItem setTag:MENU_ITEM_TAG_NOTHING];
193
     if ([lastMode isEqualToString:TEXT_CPU_USAGE]) {
203
     if ([lastMode isEqualToString:TEXT_CPU_USAGE]) {
194
         [self selectedVisualization:cpuUsageItem];
204
         [self selectedVisualization:cpuUsageItem];
195
     }
205
     }
197
     
207
     
198
     // Add Memory Usage item
208
     // Add Memory Usage item
199
     NSMenuItem *memoryUsageItem = [[NSMenuItem alloc] initWithTitle:TEXT_RAM_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
209
     NSMenuItem *memoryUsageItem = [[NSMenuItem alloc] initWithTitle:TEXT_RAM_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
200
-    [memoryUsageItem setTag:-1];
210
+    [memoryUsageItem setTag:MENU_ITEM_TAG_NOTHING];
201
     if ([lastMode isEqualToString:TEXT_RAM_USAGE]) {
211
     if ([lastMode isEqualToString:TEXT_RAM_USAGE]) {
202
         [self selectedVisualization:memoryUsageItem];
212
         [self selectedVisualization:memoryUsageItem];
203
     }
213
     }
211
         NSLog(@"Error reading GPU information\n");
221
         NSLog(@"Error reading GPU information\n");
212
     } else {
222
     } else {
213
         NSMenuItem *itemUsage = [[NSMenuItem alloc] initWithTitle:TEXT_GPU_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
223
         NSMenuItem *itemUsage = [[NSMenuItem alloc] initWithTitle:TEXT_GPU_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
214
-        [itemUsage setTag:-1];
224
+        [itemUsage setTag:MENU_ITEM_TAG_NOTHING];
215
         if ([lastMode isEqualToString:TEXT_GPU_USAGE]) {
225
         if ([lastMode isEqualToString:TEXT_GPU_USAGE]) {
216
             [self selectedVisualization:itemUsage];
226
             [self selectedVisualization:itemUsage];
217
         }
227
         }
218
         [menuVisualizations addItem:itemUsage];
228
         [menuVisualizations addItem:itemUsage];
219
         
229
         
220
         NSMenuItem *itemVRAM = [[NSMenuItem alloc] initWithTitle:TEXT_VRAM_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
230
         NSMenuItem *itemVRAM = [[NSMenuItem alloc] initWithTitle:TEXT_VRAM_USAGE action:@selector(selectedVisualization:) keyEquivalent:@""];
221
-        [itemVRAM setTag:-1];
231
+        [itemVRAM setTag:MENU_ITEM_TAG_NOTHING];
222
         if ([lastMode isEqualToString:TEXT_VRAM_USAGE]) {
232
         if ([lastMode isEqualToString:TEXT_VRAM_USAGE]) {
223
             [self selectedVisualization:itemVRAM];
233
             [self selectedVisualization:itemVRAM];
224
         }
234
         }
237
 
247
 
238
         if ([key isEqualToString:KEY_CPU_TEMPERATURE]) {
248
         if ([key isEqualToString:KEY_CPU_TEMPERATURE]) {
239
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:TEXT_CPU_TEMPERATURE action:@selector(selectedVisualization:) keyEquivalent:@""];
249
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:TEXT_CPU_TEMPERATURE action:@selector(selectedVisualization:) keyEquivalent:@""];
240
-            [item setTag:-1];
250
+            [item setTag:MENU_ITEM_TAG_NOTHING];
241
             if ([lastMode isEqualToString:TEXT_CPU_TEMPERATURE]) {
251
             if ([lastMode isEqualToString:TEXT_CPU_TEMPERATURE]) {
242
                 [self selectedVisualization:item];
252
                 [self selectedVisualization:item];
243
             }
253
             }
246
         
256
         
247
         if ([key isEqualToString:KEY_GPU_TEMPERATURE]) {
257
         if ([key isEqualToString:KEY_GPU_TEMPERATURE]) {
248
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:TEXT_GPU_TEMPERATURE action:@selector(selectedVisualization:) keyEquivalent:@""];
258
             NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:TEXT_GPU_TEMPERATURE action:@selector(selectedVisualization:) keyEquivalent:@""];
249
-            [item setTag:-1];
259
+            [item setTag:MENU_ITEM_TAG_NOTHING];
250
             if ([lastMode isEqualToString:TEXT_GPU_TEMPERATURE]) {
260
             if ([lastMode isEqualToString:TEXT_GPU_TEMPERATURE]) {
251
                 [self selectedVisualization:item];
261
                 [self selectedVisualization:item];
252
             }
262
             }
273
     [Screenshot init:self];
283
     [Screenshot init:self];
274
     NSArray *displayIDs = [Screenshot listDisplays];
284
     NSArray *displayIDs = [Screenshot listDisplays];
275
     [self updateDisplayUI:displayIDs];
285
     [self updateDisplayUI:displayIDs];
286
+    
287
+    // List available audio input devices and add menu items
288
+    NSArray *inputDevices = [EZAudioDevice inputDevices];
289
+    [menuAudio removeAllItems];
290
+    for (int i = 0; i < [inputDevices count]; i++) {
291
+        EZAudioDevice *dev = [inputDevices objectAtIndex:i];
292
+        
293
+#ifdef DEBUG
294
+        NSLog(@"Audio input device: \"%@\"\n", [dev name]);
295
+#endif
296
+        
297
+        NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[dev name] action:@selector(selectedVisualization:) keyEquivalent:@""];
298
+        [item setTag:MENU_ITEM_TAG_AUDIO];
299
+        NSString *lastModeString = [NSString stringWithFormat:TEXT_TEMPLATE_AUDIO, [dev name]];
300
+        if ([lastModeString isEqualToString:lastMode]) {
301
+            [self selectedVisualization:item];
302
+        }
303
+        [menuAudio addItem:item];
304
+    }
305
+    if ([inputDevices count] > 0) {
306
+        [menuItemAudio setHidden:NO];
307
+    }
276
 }
308
 }
277
 
309
 
278
 - (void)applicationWillTerminate:(NSNotification *)aNotification {
310
 - (void)applicationWillTerminate:(NSNotification *)aNotification {
282
         animation = nil;
314
         animation = nil;
283
     }
315
     }
284
     
316
     
317
+    // Stop previous audio data retrieval
318
+    if (microphone != nil) {
319
+        [microphone stopFetchingAudio];
320
+        microphone = nil;
321
+    }
322
+    
285
     // Remove display callback
323
     // Remove display callback
286
     [Screenshot close:self];
324
     [Screenshot close:self];
287
     
325
     
337
         animation = nil;
375
         animation = nil;
338
     }
376
     }
339
     
377
     
378
+    // Stop previous audio data retrieval
379
+    if (microphone != nil) {
380
+        [microphone stopFetchingAudio];
381
+        microphone = nil;
382
+    }
383
+    
340
     // Turn off all other LED menu items
384
     // Turn off all other LED menu items
341
     if (menuColors != nil) {
385
     if (menuColors != nil) {
342
         for (int i = 0; i < [menuColors numberOfItems]; i++) {
386
         for (int i = 0; i < [menuColors numberOfItems]; i++) {
353
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
397
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
354
         }
398
         }
355
     }
399
     }
400
+    if (menuAudio != nil) {
401
+        for (int i = 0; i < [menuAudio numberOfItems]; i++) {
402
+            [[menuAudio itemAtIndex:i] setState:NSOffState];
403
+        }
404
+    }
356
     if (menuDisplays != nil) {
405
     if (menuDisplays != nil) {
357
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
406
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
358
             [[menuDisplays itemAtIndex:i] setState:NSOffState];
407
             [[menuDisplays itemAtIndex:i] setState:NSOffState];
383
 }
432
 }
384
 
433
 
385
 - (IBAction)relistSerialPorts:(id)sender {
434
 - (IBAction)relistSerialPorts:(id)sender {
435
+    // Refill audio device list
436
+    NSArray *inputDevices = [EZAudioDevice inputDevices];
437
+    [menuAudio removeAllItems];
438
+    for (int i = 0; i < [inputDevices count]; i++) {
439
+        EZAudioDevice *dev = [inputDevices objectAtIndex:i];
440
+        NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[dev name] action:@selector(selectedVisualization:) keyEquivalent:@""];
441
+        [item setTag:MENU_ITEM_TAG_AUDIO];
442
+        NSString *lastModeString = [NSString stringWithFormat:TEXT_TEMPLATE_AUDIO, [dev name]];
443
+        if ([lastModeString isEqualToString:[[NSUserDefaults standardUserDefaults] stringForKey:PREF_LED_MODE]]) {
444
+            [self selectedVisualization:item];
445
+        }
446
+        [menuAudio addItem:item];
447
+    }
448
+    if ([inputDevices count] > 0) {
449
+        [menuItemAudio setHidden:NO];
450
+    } else {
451
+        [menuItemAudio setHidden:YES];
452
+    }
453
+    
386
     // Refill port list
454
     // Refill port list
387
     NSArray *ports = [Serial listSerialPorts];
455
     NSArray *ports = [Serial listSerialPorts];
388
     [menuPorts removeAllItems];
456
     [menuPorts removeAllItems];
389
     for (int i = 0; i < [ports count]; i++) {
457
     for (int i = 0; i < [ports count]; i++) {
390
         // Add Menu Item for this port
458
         // Add Menu Item for this port
391
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[ports objectAtIndex:i] action:@selector(selectedSerialPort:) keyEquivalent:@""];
459
         NSMenuItem *item = [[NSMenuItem alloc] initWithTitle:[ports objectAtIndex:i] action:@selector(selectedSerialPort:) keyEquivalent:@""];
392
-        [item setTag:-1];
460
+        [item setTag:MENU_ITEM_TAG_NOTHING];
393
         [menuPorts addItem:item];
461
         [menuPorts addItem:item];
394
         
462
         
395
         // Mark it if it is currently open
463
         // Mark it if it is currently open
422
     [application orderFrontColorPanel:cp];
490
     [application orderFrontColorPanel:cp];
423
 }
491
 }
424
 
492
 
425
-- (void)colorSelected:(id)sender {
493
+- (void)colorSelected:(NSColorPanel *)sender {
426
     [self setLightsColor:[sender color]];
494
     [self setLightsColor:[sender color]];
427
 }
495
 }
428
 
496
 
451
             [animation invalidate];
519
             [animation invalidate];
452
             animation = nil;
520
             animation = nil;
453
         }
521
         }
522
+        
523
+        // Stop previous audio data retrieval
524
+        if (microphone != nil) {
525
+            [microphone stopFetchingAudio];
526
+            microphone = nil;
527
+        }
454
 
528
 
455
         // Turn off all other LED menu items
529
         // Turn off all other LED menu items
456
         for (int i = 0; i < [menuColors numberOfItems]; i++) {
530
         for (int i = 0; i < [menuColors numberOfItems]; i++) {
471
             }
545
             }
472
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
546
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
473
         }
547
         }
548
+        for (int i = 0; i < [menuAudio numberOfItems]; i++) {
549
+            if ([[menuAudio itemAtIndex:i] state] == NSOnState) {
550
+                lastLEDMode = [menuAudio itemAtIndex:i];
551
+            }
552
+            [[menuAudio itemAtIndex:i] setState:NSOffState];
553
+        }
474
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
554
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
475
             if ([[menuDisplays itemAtIndex:i] state] == NSOnState) {
555
             if ([[menuDisplays itemAtIndex:i] state] == NSOnState) {
476
                 lastLEDMode = [menuDisplays itemAtIndex:i];
556
                 lastLEDMode = [menuDisplays itemAtIndex:i];
530
         animation = nil;
610
         animation = nil;
531
     }
611
     }
532
     
612
     
613
+    // Stop previous audio data retrieval
614
+    if (microphone != nil) {
615
+        [microphone stopFetchingAudio];
616
+        microphone = nil;
617
+    }
618
+    
533
     // Schedule next invocation for this animation...
619
     // Schedule next invocation for this animation...
534
     if ([mode isEqualToString:TEXT_GPU_USAGE]) {
620
     if ([mode isEqualToString:TEXT_GPU_USAGE]) {
535
         animation = [NSTimer scheduledTimerWithTimeInterval:2.0 target:self selector:@selector(visualizeGPUUsage:) userInfo:mode repeats:YES];
621
         animation = [NSTimer scheduledTimerWithTimeInterval:2.0 target:self selector:@selector(visualizeGPUUsage:) userInfo:mode repeats:YES];
569
         animation = nil;
655
         animation = nil;
570
     }
656
     }
571
     
657
     
658
+    // Stop previous audio data retrieval
659
+    if (microphone != nil) {
660
+        [microphone stopFetchingAudio];
661
+        microphone = nil;
662
+    }
663
+    
572
     // Schedule next invocation for this animation...
664
     // Schedule next invocation for this animation...
573
     animation = [NSTimer scheduledTimerWithTimeInterval:DISPLAY_DELAY target:self selector:@selector(visualizeDisplay:) userInfo:[NSNumber numberWithInteger:[sender tag]] repeats:YES];
665
     animation = [NSTimer scheduledTimerWithTimeInterval:DISPLAY_DELAY target:self selector:@selector(visualizeDisplay:) userInfo:[NSNumber numberWithInteger:[sender tag]] repeats:YES];
574
     
666
     
593
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
685
             [[menuVisualizations itemAtIndex:i] setState:NSOffState];
594
         }
686
         }
595
     }
687
     }
688
+    if (menuAudio != nil) {
689
+        for (int i = 0; i < [menuAudio numberOfItems]; i++) {
690
+            [[menuAudio itemAtIndex:i] setState:NSOffState];
691
+        }
692
+    }
596
     if (menuDisplays != nil) {
693
     if (menuDisplays != nil) {
597
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
694
         for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
598
             [[menuDisplays itemAtIndex:i] setState:NSOffState];
695
             [[menuDisplays itemAtIndex:i] setState:NSOffState];
603
     
700
     
604
     // Check if it is a display
701
     // Check if it is a display
605
     BOOL found = NO;
702
     BOOL found = NO;
606
-    if ([sender tag] > -1) {
703
+    if ([sender tag] > MENU_ITEM_TAG_NOTHING) {
607
         found = YES;
704
         found = YES;
608
         [self displayVisualization:sender];
705
         [self displayVisualization:sender];
609
     }
706
     }
610
     
707
     
708
+    // Check if it is an audio input device
709
+    if ((found == NO) && ([sender tag] == MENU_ITEM_TAG_AUDIO)) {
710
+        found = YES;
711
+        BOOL foundDev = NO;
712
+        NSArray *audioDevices = [EZAudioDevice inputDevices];
713
+        for (int  i = 0; i < [audioDevices count]; i++) {
714
+            EZAudioDevice *dev = [audioDevices objectAtIndex:i];
715
+            if ([[dev name] isEqualToString:[sender title]]) {
716
+                // Found device
717
+                foundDev = YES;
718
+                if (microphone != nil) {
719
+                    [microphone stopFetchingAudio];
720
+                    microphone = nil;
721
+                }
722
+                microphone = [EZMicrophone microphoneWithDelegate:self];
723
+                [microphone setDevice:dev];
724
+                [microphone startFetchingAudio];
725
+                break;
726
+            }
727
+        }
728
+        if (foundDev == NO) {
729
+            NSLog(@"Couldn't find device \"%@\"\n", [sender title]);
730
+            [sender setState:NSOffState];
731
+            return; // Don't store new mode
732
+        }
733
+    }
734
+    
611
     // Check if it is the manual color select item
735
     // Check if it is the manual color select item
612
-    if ([sender.title isEqualToString:TEXT_MANUAL]) {
736
+    if ((found == NO) && ([sender.title isEqualToString:TEXT_MANUAL])) {
613
         found = YES;
737
         found = YES;
614
         [self colorSelected:[NSColorPanel sharedColorPanel]];
738
         [self colorSelected:[NSColorPanel sharedColorPanel]];
615
     }
739
     }
626
                     animation = nil;
750
                     animation = nil;
627
                 }
751
                 }
628
                 
752
                 
753
+                // Stop previous audio data retrieval
754
+                if (microphone != nil) {
755
+                    [microphone stopFetchingAudio];
756
+                    microphone = nil;
757
+                }
758
+                
629
                 NSColor *color = [staticColors valueForKey:key];
759
                 NSColor *color = [staticColors valueForKey:key];
630
                 unsigned char red = [color redComponent] * 255;
760
                 unsigned char red = [color redComponent] * 255;
631
                 unsigned char green = [color greenComponent] * 255;
761
                 unsigned char green = [color greenComponent] * 255;
647
     
777
     
648
     // Store changed value in preferences
778
     // Store changed value in preferences
649
     NSUserDefaults *store = [NSUserDefaults standardUserDefaults];
779
     NSUserDefaults *store = [NSUserDefaults standardUserDefaults];
650
-    [store setObject:[sender title] forKey:PREF_LED_MODE];
780
+    if ([sender tag] == MENU_ITEM_TAG_AUDIO) {
781
+        // Prepend text for audio device names
782
+        NSString *tmp = [NSString stringWithFormat:TEXT_TEMPLATE_AUDIO, [sender title]];
783
+        [store setObject:tmp forKey:PREF_LED_MODE];
784
+    } else {
785
+        [store setObject:[sender title] forKey:PREF_LED_MODE];
786
+    }
651
     [store synchronize];
787
     [store synchronize];
652
     
788
     
653
 #ifdef DEBUG
789
 #ifdef DEBUG
695
                 [self selectedVisualization:[menuVisualizations itemAtIndex:i]];
831
                 [self selectedVisualization:[menuVisualizations itemAtIndex:i]];
696
             }
832
             }
697
         }
833
         }
834
+        for (int i = 0; i < [menuAudio numberOfItems]; i++) {
835
+            if ([[menuAudio itemAtIndex:i] state] == NSOnState) {
836
+                [self selectedVisualization:[menuAudio itemAtIndex:i]];
837
+            }
838
+        }
839
+        for (int i = 0; i < [menuDisplays numberOfItems]; i++) {
840
+            if ([[menuDisplays itemAtIndex:i] state] == NSOnState) {
841
+                [self selectedVisualization:[menuDisplays itemAtIndex:i]];
842
+            }
843
+        }
698
         if ([buttonOff state] == NSOnState) {
844
         if ([buttonOff state] == NSOnState) {
699
             [buttonOff setState:NSOffState];
845
             [buttonOff setState:NSOffState];
700
             [self turnLEDsOff:buttonOff];
846
             [self turnLEDsOff:buttonOff];
712
     [application orderFrontStandardAboutPanel:self];
858
     [application orderFrontStandardAboutPanel:self];
713
 }
859
 }
714
 
860
 
861
+- (void)updateBuffer:(float *)buffer withBufferSize:(UInt32)bufferSize {
862
+    if (microphone == nil) {
863
+        return; // Old buffer from before we changed mode
864
+    }
865
+    
866
+    // TODO visualize sound data somehow
867
+    //NSLog(@".");
868
+}
869
+
870
+// ------------------------------------------------------
871
+// ----------------- Microphone Delegate ----------------
872
+// ------------------------------------------------------
873
+
874
+- (void)microphone:(EZMicrophone *)microphone hasAudioReceived:(float **)buffer withBufferSize:(UInt32)bufferSize withNumberOfChannels:(UInt32)numberOfChannels {
875
+    __weak typeof (self) weakSelf = self;
876
+    
877
+    if (weakSelf.microphone == nil) {
878
+        return;
879
+    }
880
+    
881
+    // Getting audio data as an array of float buffer arrays that can be fed into the
882
+    // EZAudioPlot, EZAudioPlotGL, or whatever visualization you would like to do with
883
+    // the microphone data.
884
+    dispatch_async(dispatch_get_main_queue(),^{
885
+        // buffer[0] = left channel, buffer[1] = right channel
886
+        [weakSelf updateBuffer:buffer[0] withBufferSize:bufferSize];
887
+    });
888
+}
889
+
890
+- (void)microphone:(EZMicrophone *)microphone changedDevice:(EZAudioDevice *)device {
891
+    // This is not always guaranteed to occur on the main thread so make sure you
892
+    // wrap it in a GCD block
893
+    dispatch_async(dispatch_get_main_queue(), ^{
894
+        NSLog(@"Changed audio input device: %@", [device name]);
895
+    });
896
+}
897
+
715
 // ------------------------------------------------------
898
 // ------------------------------------------------------
716
 // ------------------- Visualizations -------------------
899
 // ------------------- Visualizations -------------------
717
 // ------------------------------------------------------
900
 // ------------------------------------------------------

+ 7
- 1
CaseLights/Base.lproj/MainMenu.xib View File

21
                 <outlet property="buttonLights" destination="tLQ-BA-kGu" id="FZv-Ju-l7n"/>
21
                 <outlet property="buttonLights" destination="tLQ-BA-kGu" id="FZv-Ju-l7n"/>
22
                 <outlet property="buttonOff" destination="gT4-tm-Hvn" id="EEv-lf-Qo7"/>
22
                 <outlet property="buttonOff" destination="gT4-tm-Hvn" id="EEv-lf-Qo7"/>
23
                 <outlet property="menuAnimations" destination="FJm-ND-abA" id="iGI-Hg-tms"/>
23
                 <outlet property="menuAnimations" destination="FJm-ND-abA" id="iGI-Hg-tms"/>
24
+                <outlet property="menuAudio" destination="KUj-jy-iwd" id="ct3-CS-KXG"/>
24
                 <outlet property="menuColors" destination="ZKz-ek-t6c" id="B2S-fy-Ca6"/>
25
                 <outlet property="menuColors" destination="ZKz-ek-t6c" id="B2S-fy-Ca6"/>
25
                 <outlet property="menuDisplays" destination="Qgx-6D-9dl" id="MaT-c8-dLX"/>
26
                 <outlet property="menuDisplays" destination="Qgx-6D-9dl" id="MaT-c8-dLX"/>
27
+                <outlet property="menuItemAudio" destination="gx8-7I-Lmt" id="LjY-fB-ViX"/>
26
                 <outlet property="menuItemDisplays" destination="1Cz-Xz-d16" id="rRz-n5-n2P"/>
28
                 <outlet property="menuItemDisplays" destination="1Cz-Xz-d16" id="rRz-n5-n2P"/>
27
                 <outlet property="menuPorts" destination="lFU-D0-M5p" id="pHd-AA-S3J"/>
29
                 <outlet property="menuPorts" destination="lFU-D0-M5p" id="pHd-AA-S3J"/>
28
                 <outlet property="menuVisualizations" destination="yZl-ae-7SI" id="b2b-dW-mvy"/>
30
                 <outlet property="menuVisualizations" destination="yZl-ae-7SI" id="b2b-dW-mvy"/>
697
                     <modifierMask key="keyEquivalentModifierMask"/>
699
                     <modifierMask key="keyEquivalentModifierMask"/>
698
                     <menu key="submenu" title="Displays" id="Qgx-6D-9dl"/>
700
                     <menu key="submenu" title="Displays" id="Qgx-6D-9dl"/>
699
                 </menuItem>
701
                 </menuItem>
702
+                <menuItem title="Audio Inputs" hidden="YES" id="gx8-7I-Lmt">
703
+                    <modifierMask key="keyEquivalentModifierMask"/>
704
+                    <menu key="submenu" title="Audio Inputs" id="KUj-jy-iwd"/>
705
+                </menuItem>
700
                 <menuItem title="Brightness" id="Oh0-1U-yDg">
706
                 <menuItem title="Brightness" id="Oh0-1U-yDg">
701
                     <modifierMask key="keyEquivalentModifierMask"/>
707
                     <modifierMask key="keyEquivalentModifierMask"/>
702
                     <menu key="submenu" title="Brightness" id="jRu-sM-3xB">
708
                     <menu key="submenu" title="Brightness" id="jRu-sM-3xB">
732
                         </items>
738
                         </items>
733
                     </menu>
739
                     </menu>
734
                 </menuItem>
740
                 </menuItem>
735
-                <menuItem title="Relist Serial Ports" id="jVd-gl-Z6F">
741
+                <menuItem title="Relist Devices" id="jVd-gl-Z6F">
736
                     <modifierMask key="keyEquivalentModifierMask"/>
742
                     <modifierMask key="keyEquivalentModifierMask"/>
737
                     <connections>
743
                     <connections>
738
                         <action selector="relistSerialPorts:" target="Voe-Tx-rLC" id="iFU-PL-xR8"/>
744
                         <action selector="relistSerialPorts:" target="Voe-Tx-rLC" id="iFU-PL-xR8"/>

+ 1
- 1
CaseLights/Info.plist View File

21
 	<key>CFBundleSignature</key>
21
 	<key>CFBundleSignature</key>
22
 	<string>????</string>
22
 	<string>????</string>
23
 	<key>CFBundleVersion</key>
23
 	<key>CFBundleVersion</key>
24
-	<string>172</string>
24
+	<string>180</string>
25
 	<key>LSApplicationCategoryType</key>
25
 	<key>LSApplicationCategoryType</key>
26
 	<string>public.app-category.utilities</string>
26
 	<string>public.app-category.utilities</string>
27
 	<key>LSMinimumSystemVersion</key>
27
 	<key>LSMinimumSystemVersion</key>

Loading…
Cancel
Save