-
-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor project structure and update configurations
- Added new project `openHAB.Windows.Package` to the solution. - Replaced `Any CPU` with specific platform configurations (`x86`, `x64`, `arm64`). - Updated `AppResources.cs` to use `Microsoft.Windows.ApplicationModel.Resources`. - Modified resource loader initialization in `AppResources.cs`. - Added `JsonIgnore` to `Profile` in `Connection.cs` and introduced `ProfileId`. - Created `ConnectionProfiles` class and refactored `Settings` class. - Replaced `Newtonsoft.Json` with `System.Text.Json` in `SettingsService.cs`. - Updated image assets and paths in `Package.appxmanifest`. - Added `openHAB.Windows.Package.wapproj` with project configurations. - Cleaned up `App.xaml` and removed unused `using` directives. - Updated `app.manifest` and `openHAB.Windows.csproj` for new configurations. - Added new publish profile files for different architectures. Add new project, update configs, and switch to System.Text.Json Added a new project `openHAB.Windows.Package` to the solution. Replaced `Any CPU` with specific platform configurations (`x86`, `x64`, `arm64`). Updated `AppResources.cs` to use `Microsoft.Windows.ApplicationModel.Resources`. Changed resource loader initialization in `AppResources.cs`. Added `JsonIgnore` attribute to `Profile` property in `Connection` class. Introduced `ProfileId` property and created `ConnectionProfiles` class. Updated `Settings` class to use `ConnectionProfiles.GetProfiles()`. Simplified `ConnectionProfiles` property in `Settings` class. Reformatted `LastSitemap` property in `Settings` class. Switched JSON operations to `System.Text.Json` in `SettingsService.cs`. Updated namespaces and using directives for new project structure. Added new binary image files and updated existing ones. Updated `Package.StoreAssociation.xml` for store association changes. Updated `Package.appxmanifest` for version, logo paths, and formatting. Added `openHAB.Windows.Package.wapproj` with platform configurations. Modified `App.xaml` and `App.xaml.cs` for template and namespace changes. Removed unused `openHAB.Windows.Services` namespace imports. Updated `app.manifest` and `openHAB.Windows.csproj` for new configurations. Added new publish profiles for different platforms. Signed-off-by: Christoph Hofmann <[email protected]>
- Loading branch information
Showing
85 changed files
with
303 additions
and
21,193 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
src/openHAB.Core.Client/Connection/Models/ConnectionProfiles.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
using openHAB.Core.Client.Connection.Contracts; | ||
using System.Collections.Generic; | ||
|
||
namespace openHAB.Core.Client.Connection.Models | ||
{ | ||
/// <summary> | ||
/// Manages connection profiles. | ||
/// </summary> | ||
public class ConnectionProfiles | ||
{ | ||
private static Dictionary<int, IConnectionProfile> _profiles = new Dictionary<int, IConnectionProfile>() | ||
{ | ||
{ 1, new DefaultConnectionProfile() }, | ||
{ 2, new LocalConnectionProfile() }, | ||
{ 3, new RemoteConnectionProfile() }, | ||
{ 4, new CloudConnectionProfile() } | ||
}; | ||
|
||
/// <summary> | ||
/// Gets the connection profile by the specified identifier. | ||
/// </summary> | ||
/// <param name="id">The identifier of the connection profile.</param> | ||
/// <returns>The connection profile associated with the specified identifier.</returns> | ||
public static IConnectionProfile GetProfile(int id) | ||
{ | ||
return _profiles[id]; | ||
} | ||
|
||
/// <summary> | ||
/// Gets all connection profiles. | ||
/// </summary> | ||
/// <returns>A list of all connection profiles.</returns> | ||
public static List<IConnectionProfile> GetProfiles() | ||
{ | ||
return new List<IConnectionProfile>(_profiles.Values); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file renamed
BIN
+1.42 KB
src/openHAB.Windows/Assets/StoreLogo.png → ...ckage/Images/LockScreenLogo.scale-200.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.