减少工程复杂度
This commit is contained in:
lincube
2026-03-04 16:43:10 +08:00
parent f78a56cb2c
commit b21bb490fa
27 changed files with 422 additions and 1744 deletions

View File

@@ -1425,7 +1425,11 @@ public partial class MainWindow
return null;
}
var component = runtimeDescriptor.CreateControl(_currentDesktopCellSize, _timeZoneService, _weatherDataService);
var component = runtimeDescriptor.CreateControl(
_currentDesktopCellSize,
_timeZoneService,
_weatherDataService,
_recommendationInfoService);
component.Classes.Add(DesktopComponentClass);
return component;
}
@@ -2533,7 +2537,11 @@ public partial class MainWindow
var previewHeight = previewSpan.HeightCells * previewCellSize;
var renderCellSize = Math.Clamp(previewCellSize * 1.15, 26, 110);
var previewControl = descriptor.CreateControl(renderCellSize, _timeZoneService, _weatherDataService);
var previewControl = descriptor.CreateControl(
renderCellSize,
_timeZoneService,
_weatherDataService,
_recommendationInfoService);
var previewSurface = new Border
{