ample/Ample/SoftwareList.h

47 lines
923 B
C
Raw Normal View History

2021-03-28 22:50:55 +00:00
//
// SoftwareList.h
// Ample
//
// Created by Kelvin Sherlock on 3/28/2021.
// Copyright © 2021 Kelvin Sherlock. All rights reserved.
//
#ifndef SoftwareList_h
#define SoftwareList_h
#import <Foundation/Foundation.h>
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
#import "AutocompleteControl.h"
2021-03-28 22:50:55 +00:00
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
@interface SoftwareList : NSObject <AutocompleteItem>
2021-03-28 22:50:55 +00:00
@property NSString *name;
@property NSString *title;
@property NSArray *items;
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
-(SoftwareList *)filter: (NSString *)filter;
2021-03-28 22:50:55 +00:00
@end
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
@interface Software : NSObject <AutocompleteItem>
2021-03-28 22:50:55 +00:00
@property NSString *name;
@property NSString *title;
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
@property NSString *compatibility;
@property NSString *list;
-(NSString *)fullName;
@end
@interface SoftwareSet : NSObject <NSFastEnumeration, AutoCompleteDelegate>
+(instancetype)softwareSetForMachine: (NSString *)machine;
-(BOOL)nameIsUnique: (NSString *)name;
2021-03-28 22:50:55 +00:00
@end
Squashed commit of the following: commit 1dd1d6d3eee928d283dafbaf4432b053dff65ac2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Thu May 27 13:30:38 2021 -0400 0.232 rom update commit cfb7f9a4d1647c41fab3328bada0f37bdb041983 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:31:16 2021 -0400 fix resizing to prevent horizontal scrolling commit 5c393ab5a95c9e53c4ef1e0b3f2b77db93e1c29b Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Wed May 26 20:01:48 2021 -0400 esc should close the menu if visible, otherwise clear the text. commit 7da142b64280c39e216584cedb7fb14243d573f0 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:17:10 2021 -0400 show software short name unless it's ambiguous. commit 6f3b3bef5e18e78619959613e28064eb6251ce27 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:47 2021 -0400 cleanup some auto complete rough edges commit 4988d8b266b8b11e519bcb5aab05ad2c3ffe5c23 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 23:16:24 2021 -0400 fix commit 6d4bf94fd6b4850564b705ea15e91079b00346c2 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:28 2021 -0400 clean up autocomplete a little... commit 3722271e51d93599903bccc721dc1de61f0aae72 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Tue May 25 19:13:07 2021 -0400 move auto complete logic to SoftwareSet commit 04cc83ecbe9ee4c9100305712c47a11359327734 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:46:39 2021 -0400 software - keep the list name to differentiate in case of name clashes. commit 8e5b5dc7e283f760a16011308298e999110fc052 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 20:45:13 2021 -0400 Autocomplete - limit menu content width to the clip view content width. prevents horizontal scrolling. commit 356048d450447485bb33a4261018f85dac19a134 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:45:42 2021 -0400 add auto complete software list to the launch window. commit 9dc72b702c9b36d490349f291c10b98b56178567 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:44:28 2021 -0400 autocomplete control. commit 40eee83f56d957c64e0f8d927486f13165b9e120 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Mon May 24 18:39:32 2021 -0400 add filters to software list. commit cebfbaa545441f061cffafe8ca93db2377240a06 Author: Kelvin Sherlock <ksherlock@gmail.com> Date: Sun May 23 11:59:00 2021 -0400 add compatibility field for software list filtering.
2021-05-27 23:42:28 +00:00
//NSArray<SoftwareList *> *SoftwareListForMachine(NSString *machine);
2021-03-28 22:50:55 +00:00
#endif /* SoftwareList_h */