Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to v0.1.0-rc2 #40

Merged
merged 12 commits into from
Oct 12, 2024
Merged

Update to v0.1.0-rc2 #40

merged 12 commits into from
Oct 12, 2024

Conversation

GamerVII-NET
Copy link
Collaborator

No description provided.

GamerVII-NET and others added 12 commits August 7, 2024 11:02
Caught IOException explicitly to provide more granular error handling. This allows to throw the IOException immediately while preserving the behavior for general exceptions. Adjusted throttler release comment to remove redundant text.
This commit updates the process start information in ApiProcedures.cs to redirect standard output and error. It also sets UseShellExecute to false and CreateNoWindow to true for better process control and visibility.
* Add support for bug tracking and enhance profile management
* Add ability to change installation directory dynamically
Updated the SystemIOProcedures helper to use Path.GetFullPath for constructing and validating paths. This ensures absolute references, thereby enhancing path accuracy and security checks when manipulating directories and files.
Implement a new authentication method using OAuth tokens across several classes to enhance security. This method allows users to authenticate using an access token, improving the flexibility and modernizing the authentication process.
Introduce ProcessHelper with a StartWatch method to observe and log module changes of a given process. This implementation uses reactive extensions to handle the monitoring and provides module addition and removal logging.
Added a size check to skip overwriting files that are 100MB or larger in the `SystemIOProcedures` class. This change ensures large files are not unnecessarily replaced, optimizing performance and avoiding potential issues with large file handling.
Ensure the process has not exited before attempting to kill it to prevent an InvalidOperationException. Added a try-catch block to safely handle exceptions if the process termination fails.
Created a comprehensive README guide for the Gml.Client project. It includes step-by-step instructions for cloning, setting up, building, running, and publishing the project, as well as contributing guidelines and additional resources.
@GamerVII-NET GamerVII-NET merged commit eacbbb5 into master Oct 12, 2024
GamerVII-NET added a commit that referenced this pull request Nov 25, 2024
* Add folder icon and directory selection feature

Introduced a folder icon for the installation directory setting UI and implemented functionality to change the installation directory. Updated resource files to include new string entries for "InstallationDirectory" and "Edit" in multiple languages.

* Add Click event to GmlButton component

Implemented a new Click event for the GmlButton component, enhancing its functionality. Updated the axaml template to bind the button's click action and ensured command execution on click events. Also added handler in SettingsPageView to utilize the new Click event.

* Remove OnPointerReleased override from GmlButton

The OnPointerReleased method was overriding base functionality, which is now removed to restore default behavior. This change ensures that the button handles pointer events as per the standard implementation, preventing unexpected behavior.

* Refactor settings initialization and folder change logic

Separated responsibilities for initialization steps into distinct methods in `ServiceLocator`. Enhanced `SettingsPageViewModel` to save the installation directory upon changes. Modified `OpenFileDialog` to use new folder picker API and propagate the folder change correctly.

* Add "Files" localization and update description format

Added a new "Files" string to the resource files for localization support. Updated the OverviewPageViewModel to include the "Files" string in its description format, enhancing clarity for file-related messages.

* Refactor (#40)

* Refactor converters and optimize ProfileChanges handling

Updated converters to ensure return values are non-nullable and handle exceptions gracefully. Optimized `ProfileChanges` handling by using a dedicated async method and made various minor improvements such as marking properties as private.

* Refactor ServiceNotFoundException constructor.

Simplify initialization of NotFoundedService property directly in the constructor. This reduces the code complexity and enhances readability.

* Refactor `ServiceLocator` for readability and simplicity

Simplified handler attachment with discards, removed redundant braces, and eliminated unnecessary return statement in `RegisterLocalizationService`. These changes improve code readability and maintainability without altering functionality.

* Add detailed documentation comments and code refinements

Enhance interface and class method documentation with detailed descriptions, parameters, and return type annotations. Refactor dependency initialization in LocalStorageService, improve encapsulation with "init" properties for immutable fields, and remove redundant constructor in SystemService.

* Refactor ViewModels and streamline code

Simplified several ViewModel, Model, and View implementations for better readability and maintainability. Removed unnecessary dependencies and streamlined property initializations. Also added event handling for window close functionality.

* Refactor and clean up multiple classes for better readability

Refactored various classes to improve code readability and maintainability. Changes include removing unnecessary usings, adjusting method placements, and cleaning up formatting inconsistencies. This enhances the overall structure and readability without altering core functionality.
GamerVII-NET added a commit that referenced this pull request Nov 25, 2024
* Refactor LoginPageViewModel and update AsyncStreamToImageLoader

This commit refactors LoginPageViewModel to change the type of _screen from IScreen to MainWindowViewModel. This allows the app to subscribe to the 'OnClosed' event of the main window, and dispose of connections when the window is closed to prevent memory leaks. AsyncStreamToImageLoader has also been updated to clear avatar image classes upfront and enhance filename checking mechanism to prevent non-loaded images.

* Update submodule link Gml.Client

* Update background component in MainWindow

Updated the background image's component in MainWindow.axaml file. Added a class attribute, which can be used for styling or Javascript manipulation in the future.

* Remove invalid character from document.svg

The first character of the document.svg file in the Gml.Launcher/Assets/Images directory was an invalid character and is now removed. This fix ensures that the SVG file is correctly formed and interprets as expected.

* Add 'launcher' project and comment out language combo box

Added a new 'launcher' project to the Gml.Launcher.sln file and made adjustments to project settings for consistency. Additionally, commented out the language selection combo box in the SettingsPageView.axaml as it is currently not in use.

* Update submodule Gml.Client

* Update submodule Update submodule link Gml.Client

* Switch host and update debugging settings

Furthermore, the debugging settings in App.axaml.cs have been updated to not debug mode, and the return value in case of null 'actualVersion' has been set to true in SplashScreenViewModel.cs.

* Optimize system data loading process

The previous implementation executed the tasks for refreshing the drive, motherboard, and CPU lists sequentially. This was unnecessarily time-consuming. With the new implementation, these tasks are run concurrently using Task.WhenAll method for better performance and efficiency.

* Change execution context for MainWindow in debug mode

This update modifies the execution context for MainWindow in the Gml.Launcher App. Previously, it was running in non-debug mode. Now, it is set up to run in debug mode.

* Disable window resizing and update pointer events handling

A new property `CanResize=False` has been added to the MainWindow.axaml to prevent the window from being resized. The pointer events handling logic was moved from OverviewPageView to MainWindow. This was done to ensure better control over dragging behavior and to prevent inappropriate actions during specific interactions.

* Update settings validation for window size

Improved the validation and error-handling approach for setting window size parameters. Now, the windowWidth and windowHeight values are only updated when numeric values are provided. If non-numeric values are input, they will be reset to default.

* Remove commented out code in MainWindow.axaml.cs

* Added default font

* Update font styles and host URL

This commit updates the font styles across several components, improving text readability and consistency. It also switches the host URL in the ResourceKeysDictionary to a production-ready address.

* Update submodule link Gml.Client

* Update submodule link Gml.Client

* Update submodule link Gml.Client

* Remove unnecessary whitespace in OverviewPageViewModel

This commit eliminates an extra space in the OverviewPageViewModel.cs file. The removal improves code readability and adheres to best coding practices.

* Update submodule link Gml.Client

* Add new game session management and enhance game profile features

Enhanced game profile features by adding support for system types, file and profile session handling functionalities. Changes in the IGameProfile interface allow for game sessions to be locally stored and accessed. Introduced ProfileState type in the ProfileState enum. Also updated functionality to include OS specifics in process creation. This update increases compatibility across different systems and aids in clearer session management.

* Refactor code for skin rendering and noise string conversion

Specifically, the update handles question mark in the value for noise string conversion and it also removes unnecessary spaces in ProfilePageView.axaml. Moreover, unnecessary comments in ProfilePageViewModel.cs are cleaned up and HTTP header in skin rendering is updated to include User-Agent information.

* Update ProfileUserControl design

Changed the default skin URL to a new one, adjusted image and text alignment, and increased opacity of the profile gradient.

* Refactor client module for improved readability

Refactored the Gml.Client module to enhance code readability and maintainability. This involved restructuring functions, renaming variables for clarity, and adding comments where necessary. No functional changes were made to ensure existing behavior is preserved.

* Add architecture check in splash screen initialization

Updated SplashScreenViewModel to include the process architecture in version checks. This helps ensure the correct software version is retrieved based on both OS type and architecture.

* Update settings handling in OverviewPageViewModel

Change default settings handling in `OverviewPageViewModel` to use `SettingsInfo.Default` when no settings are found. Add screen dimensions and full-screen settings to profile creation details.

* Enhance process restart commands for Linux and Windows

Updated the process restart commands to properly handle filenames with spaces or special characters on both Linux and Windows. For Linux, enclosed filenames within single quotes and adjusted the process start command. For Windows, added double quotes around filenames to ensure proper execution.

* Refactor method names and update host URL

Renamed the method `PrepareLaunch` to `GetProfileInfo` for better clarity. Also, switched the host URL to the production endpoint in the ResourceKeysDictionary file. Commented out sample profile info in ProfileInfoComponent for a cleaner initialization.

* Update client processing logic.

Refactor the existing client-side logic to improve performance and readability. Adjust function naming and streamline data handling to reduce complexity.

* Add online player component and Java not found error handler

Introduced a new UI component to display online server player counts and added corresponding localization entries. Also, included error handling for missing Java installations, displaying appropriate localized messages.

* Switch ProfileUserControl to ItemsControl and add Spacing

Updated ProfileUserControl from TemplatedControl to ItemsControl to support dynamic item presentations. Introduced a new Spacing property to allow custom spacing between items. Additionally, moved ProfileInfoComponent and GmlButton from the UserControl template to the ProfilePageView for better separation of concerns.

* Add URL redirect attached property

Introduce `UrlRedirectProperty` to handle URL redirections in controls. This property changes start a process to open the URL with the default system browser, enhancing the app's interactivity.

* Add additional button and group ProfilePageView buttons

Reorganized the buttons on the ProfilePageView into a horizontal stack panel, adding a new Icon Additional button alongside the existing TextIcon Primary button. Both buttons execute the OpenLinkCommand with the same URL but have distinct visual styles.

* Update submodule link Gml.Client

* Update submodule link Gml.Client

* Update Update submodule link Gml.Client

* Update ProgressBar component descriptions

Added a minimum width to the description TextBlock in ProgressBar.axaml to ensure better layout consistency. Changed the default value of the Description property to a more informative example in ProgressBar.axaml.cs.

* Add "Stay" string constant to resources

Added "Stay" string for localization in English and Russian resource files. Updated designer and resource dictionary templates to include the new constant.

* Refactor profile loading and update counts

This commit refactors the profile loading logic into a separate `LoadProfiles` method and updates the `HomeCommand` and `ProfilesChanges` subscriptions to call this method. Additionally, it introduces reactive properties for `MaxCount` and `LoadedCount`, and a method to update the load process description based on these counts.

* Update host URL to use test environment

Replaced the hardcoded local host URL with the test environment URL for consistency and proper testing. Commented out the previous URLs to keep the history intact.

* Reorder method calls for proper Discord RPC initialization.

Moved `LoadProfiles` call before `LoadDiscordRpc` to ensure profiles are loaded before attempting to initialize and update Discord RPC. This change prevents potential issues arising from uninitialized profiles during the RPC update process.

* Feature/change install folder (#41)

* Add folder icon and directory selection feature

Introduced a folder icon for the installation directory setting UI and implemented functionality to change the installation directory. Updated resource files to include new string entries for "InstallationDirectory" and "Edit" in multiple languages.

* Add Click event to GmlButton component

Implemented a new Click event for the GmlButton component, enhancing its functionality. Updated the axaml template to bind the button's click action and ensured command execution on click events. Also added handler in SettingsPageView to utilize the new Click event.

* Remove OnPointerReleased override from GmlButton

The OnPointerReleased method was overriding base functionality, which is now removed to restore default behavior. This change ensures that the button handles pointer events as per the standard implementation, preventing unexpected behavior.

* Refactor settings initialization and folder change logic

Separated responsibilities for initialization steps into distinct methods in `ServiceLocator`. Enhanced `SettingsPageViewModel` to save the installation directory upon changes. Modified `OpenFileDialog` to use new folder picker API and propagate the folder change correctly.

* Add "Files" localization and update description format

Added a new "Files" string to the resource files for localization support. Updated the OverviewPageViewModel to include the "Files" string in its description format, enhancing clarity for file-related messages.

* Refactor (#40)

* Refactor converters and optimize ProfileChanges handling

Updated converters to ensure return values are non-nullable and handle exceptions gracefully. Optimized `ProfileChanges` handling by using a dedicated async method and made various minor improvements such as marking properties as private.

* Refactor ServiceNotFoundException constructor.

Simplify initialization of NotFoundedService property directly in the constructor. This reduces the code complexity and enhances readability.

* Refactor `ServiceLocator` for readability and simplicity

Simplified handler attachment with discards, removed redundant braces, and eliminated unnecessary return statement in `RegisterLocalizationService`. These changes improve code readability and maintainability without altering functionality.

* Add detailed documentation comments and code refinements

Enhance interface and class method documentation with detailed descriptions, parameters, and return type annotations. Refactor dependency initialization in LocalStorageService, improve encapsulation with "init" properties for immutable fields, and remove redundant constructor in SystemService.

* Refactor ViewModels and streamline code

Simplified several ViewModel, Model, and View implementations for better readability and maintainability. Removed unnecessary dependencies and streamlined property initializations. Also added event handling for window close functionality.

* Refactor and clean up multiple classes for better readability

Refactored various classes to improve code readability and maintainability. Changes include removing unnecessary usings, adjusting method placements, and cleaning up formatting inconsistencies. This enhances the overall structure and readability without altering core functionality.

* Add new error message for folder change failures

This commit adds an error message for unsuccessful attempts to change the installation folder. It updates resource files with the new error message and modifies relevant ViewModel and View files to handle and display the error appropriately.

* Update submodule link Gml.Core
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants