init
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
---
|
||||
source_files:
|
||||
- DTS Viewer/DTS.Viewer.Modules/DTS.Viewer.ViewerSettings/Properties/AssemblyInfo.cs
|
||||
generated_at: "2026-04-17T16:13:15.473185+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "10fed443f1f9bdae"
|
||||
---
|
||||
|
||||
# Properties
|
||||
|
||||
### Purpose
|
||||
Provides assembly-level metadata for the `DTS.Viewer.ViewerSettings` assembly. This module contains standard .NET assembly attributes that control versioning, COM visibility, and product identification. It exists solely to define assembly characteristics and contains no executable logic.
|
||||
|
||||
### Public Interface
|
||||
No public functions, classes, or methods. This module consists entirely of assembly-level attribute declarations:
|
||||
- `AssemblyTitle`: "DTS.Viewer.ViewerSettings"
|
||||
- `AssemblyVersion`: "1.0.0.0"
|
||||
- `AssemblyFileVersion`: "1.0.0.0"
|
||||
- `ComVisible`: false
|
||||
- `Guid`: "4733690a-cb08-4c2e-853a-9339be13ac28"
|
||||
|
||||
### Invariants
|
||||
- `ComVisible` is set to `false`, making types in this assembly invisible to COM components by default.
|
||||
- Version numbers follow the four-part versioning scheme (Major.Minor.Build.Revision).
|
||||
|
||||
### Dependencies
|
||||
**Depends on:**
|
||||
- `System.Reflection`
|
||||
- `System.Runtime.CompilerServices`
|
||||
- `System.Runtime.InteropServices`
|
||||
|
||||
**Depended on by:** Not determinable from source alone (assembly-level metadata has no direct consumers in source).
|
||||
|
||||
### Gotchas
|
||||
- `AssemblyDescription` is empty, providing no documentation
|
||||
@@ -0,0 +1,47 @@
|
||||
---
|
||||
source_files:
|
||||
- DTS Viewer/DTS.Viewer.Modules/DTS.Viewer.ViewerSettings/Resources/TranslateExtension.cs
|
||||
- DTS Viewer/DTS.Viewer.Modules/DTS.Viewer.ViewerSettings/Resources/StringResources.Designer.cs
|
||||
generated_at: "2026-04-17T16:11:57.317124+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "c1490f04f3bdab0f"
|
||||
---
|
||||
|
||||
# Resources
|
||||
|
||||
### Purpose
|
||||
This module provides localization support for the ViewerSettings feature through a XAML markup extension and strongly-typed resource access. The `TranslateExtension` allows XAML bindings to localized strings, while `StringResources` provides compile-time-safe access to localized strings related to calibration behavior settings.
|
||||
|
||||
### Public Interface
|
||||
|
||||
**TranslateExtension** (inherits `MarkupExtension`)
|
||||
- `TranslateExtension(string key)` - Constructor accepting the resource key to look up.
|
||||
- `ProvideValue(IServiceProvider serviceProvider)` - Returns the localized string from `StringResources.ResourceManager.GetString(_key)`. Returns `"#stringnotfound#"` if key is null/empty, or `"#stringnotfound# " + _key` if the key is not found in resources.
|
||||
|
||||
**StringResources** (auto-generated)
|
||||
- `ResourceManager` - Static property returning the cached `ResourceManager` instance for the `"DTS.Viewer.ViewerSettings.Resources.StringResources"` resource name.
|
||||
- `Culture` - Static property for getting/setting the `CultureInfo` for resource lookups.
|
||||
- `CalibrationBehavior_LinearIfAvailable` - Localized string: "Use the linear sensitivity, if available".
|
||||
- `CalibrationBehavior_NonLinearIfAvailable` - Localized string: "Use the non-linear sensitivity, if available".
|
||||
- `CalibrationBehavior_UseBothIfAvailable` - Localized string: "Use both sensitivities, if available, as separate channels".
|
||||
- `CalibrationBehaviorText` - Localized string: "Calibration Behavior".
|
||||
|
||||
### Invariants
|
||||
- `TranslateExtension._key` is set at construction time and cannot be changed.
|
||||
- `StringResources` class is `internal` and all members are `internal`.
|
||||
- The resource manager is lazily initialized on first access.
|
||||
|
||||
### Dependencies
|
||||
**Depends on:**
|
||||
- `System.Windows.Markup` (`MarkupExtension`, `MarkupExtensionReturnTypeAttribute`)
|
||||
- `System.Resources` (`ResourceManager`)
|
||||
- `System.Globalization` (`CultureInfo`)
|
||||
|
||||
**Depended on by:** Not determinable from source alone, but likely used by XAML files in the ViewerSettings module.
|
||||
|
||||
### Gotchas
|
||||
- **Fallback string format:** When a key is not found, the returned string includes the key name appended after `"#stringnotfound# "`. This is useful for debugging but may appear in production if resources are missing.
|
||||
- **Auto-generated file:** `StringResources.Designer.cs` is auto-generated and should not be manually edited. Changes should be made to the corresponding `.resx` file.
|
||||
|
||||
---
|
||||
@@ -0,0 +1,36 @@
|
||||
---
|
||||
source_files:
|
||||
- DTS Viewer/DTS.Viewer.Modules/DTS.Viewer.ViewerSettings/View/ViewerSettingsView.xaml.cs
|
||||
generated_at: "2026-04-17T16:13:15.474625+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "3dbea35de842a6d9"
|
||||
---
|
||||
|
||||
# View
|
||||
|
||||
### Purpose
|
||||
Provides assembly-level metadata for the `DTS.Viewer.ViewerSettings` assembly. This module contains standard .NET assembly attributes that control versioning, COM visibility, and product identification. It exists solely to define assembly characteristics and contains no executable logic.
|
||||
|
||||
### Public Interface
|
||||
No public functions, classes, or methods. This module consists entirely of assembly-level attribute declarations:
|
||||
- `AssemblyTitle`: "DTS.Viewer.ViewerSettings"
|
||||
- `AssemblyVersion`: "1.0.0.0"
|
||||
- `AssemblyFileVersion`: "1.0.0.0"
|
||||
- `ComVisible`: false
|
||||
- `Guid`: "4733690a-cb08-4c2e-853a-9339be13ac28"
|
||||
|
||||
### Invariants
|
||||
- `ComVisible` is set to `false`, making types in this assembly invisible to COM components by default.
|
||||
- Version numbers follow the four-part versioning scheme (Major.Minor.Build.Revision).
|
||||
|
||||
### Dependencies
|
||||
**Depends on:**
|
||||
- `System.Reflection`
|
||||
- `System.Runtime.CompilerServices`
|
||||
- `System.Runtime.InteropServices`
|
||||
|
||||
**Depended on by:** Not determinable from source alone (assembly-level metadata has no direct consumers in source).
|
||||
|
||||
### Gotchas
|
||||
- `AssemblyDescription` is empty, providing no documentation
|
||||
@@ -0,0 +1,45 @@
|
||||
---
|
||||
source_files:
|
||||
- DTS Viewer/DTS.Viewer.Modules/DTS.Viewer.ViewerSettings/ViewModel/ViewerSettingsViewModel.cs
|
||||
generated_at: "2026-04-17T16:30:27.297982+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "5cfb0f37e98d2924"
|
||||
---
|
||||
|
||||
# ViewModel
|
||||
|
||||
### Purpose
|
||||
This module provides the ViewModel for viewer settings, specifically managing calibration behavior configuration. It allows users to select from available calibration behaviors (LinearIfAvailable, NonLinearIfAvailable, UseBothIfAvailable) and handles visibility states for settings UI based on application events. It participates in the Prism MVVM architecture as a configurable settings component.
|
||||
|
||||
### Public Interface
|
||||
|
||||
**Class: `ViewerSettingsViewModel`** (extends `BaseViewModel<IViewerSettingsViewModel>`, implements `IViewerSettingsViewModel`)
|
||||
|
||||
**Constructor:**
|
||||
- `ViewerSettingsViewModel(IViewerSettingsView view, IRegionManager regionManager, IEventAggregator eventAggregator, IUnityContainer unityContainer)` - Initializes the view model, sets up interaction requests, and stores dependencies.
|
||||
|
||||
**Properties:**
|
||||
- `View` (`IViewerSettingsView`) - Gets or sets the associated view interface.
|
||||
- `Parent` (`IBaseViewModel`) - Gets or sets the parent view model.
|
||||
- `NotificationRequest` (`InteractionRequest<Notification>`) - Interaction request for notifications.
|
||||
- `ConfirmationRequest` (`InteractionRequest<Confirmation>`) - Interaction request for confirmations.
|
||||
- `HeaderInfo` (`string`) - Returns "SettingsRegion".
|
||||
- `IsBusy` (`bool`) - Busy state indicator.
|
||||
- `IsDirty` (`bool`) - Dirty state indicator.
|
||||
- `IsNavigationIncluded` (`bool`) - Navigation inclusion flag.
|
||||
- `CalibrationBehaviorSettingVisibility` (`Visibility`) - Controls visibility of calibration behavior setting UI; publishes `ViewerSettingsVisibilityChangedEvent` when changed.
|
||||
- `OverallSettingsVisibility` (`Visibility`) - Computed property; returns `Visible` if `CalibrationBehaviorSettingVisibility` is `Visible`, otherwise `Collapsed`.
|
||||
- `AvailableCalibrationBehaviors` (`DisplayedCalibrationBehavior[]`) - Thread-safe, lazily-initialized array of available calibration options.
|
||||
- `CalibrationBehaviorSetting` (`DisplayedCalibrationBehavior`) - Gets or sets the current calibration behavior; publishes `CalibrationBehaviorSettingChangedEvent` on change.
|
||||
|
||||
**Methods:**
|
||||
- `void Initialize()` - Empty override.
|
||||
- `void Initialize(object parameter)` - Sets `Parent` from parameter and subscribes to events.
|
||||
- `void PublishChanges()` - Empty method (implementation appears incomplete).
|
||||
|
||||
**Events:**
|
||||
- `PropertyChanged` (`PropertyChangedEventHandler`) - Property change notification event.
|
||||
|
||||
### Invariants
|
||||
- `OverallSettingsVisibility` is `Visible` if and only if `CalibrationBehaviorSettingVisibility
|
||||
Reference in New Issue
Block a user