mirror of
https://github.com/amiayweb/Hytale-F2P.git
synced 2026-02-26 10:41:56 -03:00
Merge GPU preference feature branch to main branch version 2.0.2 for testing (#3)
* modernized UI for GPU Preference option * feat: auto-detect dedicated GPU on hybrid laptops (iGPU+dGPU) * feat: detailed GPU info in auto-detection feature on startup * feat: add GPU options for launcher - Add GPU preference setting (Auto/Integrated/Dedicated) - Implement Linux GPU selection with DRI_PRIME and NVIDIA env vars - Add GPU detection using Electron's app.getGPUInfo() - Update settings UI with GPU preference dropdown - Integrate GPU preference into game launch process * feat: auto-detect dedicated GPU on hybrid laptops (iGPU+dGPU) * added fallbacks to and option to use integrated GPU. * add package-lock and fix deps version * changed 'Nvidia' string to 'NVIDIA' * fix: selecting `dedicated` option while using nvidia GPU did not set its specific env variables * remove unused `CONFIG_FILE` variable on launcher core modules * fix: duplicated save-load gpu detection functions * move game option settings to the top, while custom java to the bottom * fix: settings-header margin-bottom from 3rem to 1rem and supress line-clamp warning
This commit is contained in:
@@ -1005,6 +1005,7 @@ body {
|
||||
transform: translateY(0.5rem);
|
||||
transition: all 0.3s ease 0.1s;
|
||||
display: -webkit-box;
|
||||
line-clamp: 2;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
@@ -1888,6 +1889,7 @@ body {
|
||||
line-height: 1.5;
|
||||
margin: 0.75rem 0;
|
||||
display: -webkit-box;
|
||||
line-clamp: 3;
|
||||
-webkit-line-clamp: 3;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
@@ -2675,6 +2677,7 @@ body {
|
||||
color: rgba(255, 255, 255, 0.5);
|
||||
line-height: 1.4;
|
||||
display: -webkit-box;
|
||||
line-clamp: 2;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
@@ -3095,6 +3098,7 @@ body {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: -webkit-box;
|
||||
line-clamp: 2;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
word-break: break-word;
|
||||
@@ -3758,7 +3762,7 @@ body {
|
||||
}
|
||||
|
||||
.settings-header {
|
||||
margin-bottom: 3rem;
|
||||
margin-bottom: 1rem;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@@ -4047,6 +4051,14 @@ body {
|
||||
font-size: 0.75rem;
|
||||
}
|
||||
|
||||
.gpu-detection-info {
|
||||
margin-top: 0.5rem;
|
||||
font-size: 0.8rem;
|
||||
color: rgba(255, 255, 255, 0.7);
|
||||
font-weight: 500;
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
#settings-page {
|
||||
opacity: 0;
|
||||
@@ -4078,7 +4090,53 @@ body {
|
||||
background: linear-gradient(135deg, #a855f7, #60a5fa);
|
||||
}
|
||||
|
||||
|
||||
.segmented-control {
|
||||
display: flex;
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
border: 1px solid rgba(255, 255, 255, 0.1);
|
||||
border-radius: 8px;
|
||||
backdrop-filter: blur(10px);
|
||||
overflow: hidden;
|
||||
transition: all 0.3s ease;
|
||||
}
|
||||
.segmented-control input[type="radio"] {
|
||||
display: none;
|
||||
}
|
||||
.segmented-control label {
|
||||
flex: 1;
|
||||
padding: 0.75rem 1rem;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s ease;
|
||||
color: #d1d5db;
|
||||
font-size: 0.875rem;
|
||||
background: transparent;
|
||||
border-right: 1px solid rgba(255, 255, 255, 0.1);
|
||||
font-family: 'JetBrains Mono', monospace;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.05em;
|
||||
font-weight: 500;
|
||||
}
|
||||
.segmented-control label:last-child {
|
||||
border-right: none;
|
||||
}
|
||||
.segmented-control input[type="radio"]:checked + label {
|
||||
background: linear-gradient(135deg, #9333ea, #3b82f6);
|
||||
color: white;
|
||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
|
||||
}
|
||||
.segmented-control label:hover {
|
||||
background: rgba(255, 255, 255, 0.1);
|
||||
color: white;
|
||||
}
|
||||
.segmented-control input[type="radio"]:checked + label:hover {
|
||||
background: linear-gradient(135deg, #7c3aed, #2563eb);
|
||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
.segmented-control:focus-within {
|
||||
border-color: rgba(147, 51, 234, 0.3);
|
||||
box-shadow: 0 0 20px rgba(147, 51, 234, 0.1);
|
||||
}
|
||||
|
||||
|
||||
#update-popup-overlay {
|
||||
|
||||
Reference in New Issue
Block a user