feat: add recent LUT shortcuts and move canvas controls to the lower corners

这个提交包含在:
mac 于 2026-11-05 12:25:26 +08:00 提交
1 父节点 16b20af39a
当前提交 beccf2fc01
9 个文件已更改
+83 -25

没有与搜索条件相匹配的文件

+10
查看文件
@@ -251,6 +251,16 @@ extern "C" int DYRunDiagnostics(void) { @autoreleasepool {
[serviceContent setFrameOrigin:NSMakePoint(123,77)];
run.record(@"browser-remote-later-content-origin-is-repaired",NSEqualRects([serviceRoot convertRect:serviceRoot.bounds toView:nil],serviceViewport));
run.record(@"browser-remote-origin-repair-keeps-host-frame-and-hidden-fixture",NSEqualRects(serviceGeometry.frame,serviceFrame)&&!serviceGeometry.visible);[serviceBrowser close];
NSString *recentA=[geometryLibrary.rootURL.path stringByAppendingPathComponent:@"first.cube"],*recentB=[geometryLibrary.rootURL.path stringByAppendingPathComponent:@"second.cube"];
[geometryLibrary recordUsedPath:recentA];[geometryLibrary recordUsedPath:recentB];
NSString *fullFolderKey=[@"com.dayu.color.lookLUTPreview.selectedFolder|" stringByAppendingString:geometryLibrary.rootURL.path];
[NSUserDefaults.standardUserDefaults setObject:@"*" forKey:fullFolderKey];id originalFolder=[NSUserDefaults.standardUserDefaults objectForKey:fullFolderKey];
NSView *recentParent=[[[NSView alloc]initWithFrame:NSMakeRect(0,0,424,150)]autorelease];
DYLUTBrowser *recentBrowser=[[[DYLUTBrowser alloc]initWithLibrary:geometryLibrary preview:nil selectedPath:recentA palette:@{} selection:nil]autorelease];[recentBrowser embedRecentInView:recentParent];
NSView *recentRoot=[recentBrowser valueForKey:@"root"];NSScrollView *recentGrid=[recentBrowser valueForKey:@"gridScroll"];
run.record(@"recent-lut-shortcuts-reuse-adaptive-grid-without-browser-chrome",recentBrowser.visible&&recentGrid.superview==recentRoot&&NSContainsRect(recentRoot.bounds,recentGrid.frame)&&!recentGrid.hasHorizontalScroller&&[(NSView*)[recentBrowser valueForKey:@"splitView"]isHidden]&&[(NSView*)[recentBrowser valueForKey:@"search"]isHidden]);
[geometryLibrary recordUsedPath:recentA];[recentBrowser refreshRecentSelection:recentA];NSArray *recentEntries=[recentBrowser valueForKey:@"visibleEntries"];
run.record(@"recent-lut-refresh-follows-acknowledged-history-and-preserves-browser-preference",recentEntries.count==2&&[recentEntries[0][@"path"]isEqual:recentA]&&(!originalFolder?[NSUserDefaults.standardUserDefaults objectForKey:fullFolderKey]==nil:[originalFolder isEqual:[NSUserDefaults.standardUserDefaults objectForKey:fullFolderKey]]));[recentBrowser close];
for(NSString *key in NSUserDefaults.standardUserDefaults.dictionaryRepresentation.allKeys)if([key containsString:geometryLibrary.rootURL.path])[NSUserDefaults.standardUserDefaults removeObjectForKey:key];
DYDiagnosticManager *uiHost=[[[DYDiagnosticManager alloc]init]autorelease];DYCreateParameters(uiHost,nil);
DYInspector *inspector=[[[DYInspector alloc]initWithAPIManager:uiHost]autorelease];[inspector refresh];