feat: tabbed settings dialog (pill tabs, full-bleed panel), hover color setting, title bar grab cursor (v1.9.2)
This commit is contained in:
1 parent
1a6de71ff6
commit
701eafa744
12 files changed
+1064
-221
No files matched your search
@@ -0,0 +1,28 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'window_persistence.dart';
|
||||
|
||||
/// Arayüzdeki tüm hover vurgularının rengi. Ayarlar > Genel'den seçilir,
|
||||
/// window.json'da kalıcıdır.
|
||||
class HoverColor {
|
||||
HoverColor._();
|
||||
|
||||
static const List<Color> palette = [
|
||||
Color(0xFFF44336), // kırmızı
|
||||
Color(0xFFFF9800), // turuncu
|
||||
Color(0xFFFFD54F), // sarı
|
||||
Color(0xFF4CAF50), // yeşil
|
||||
Color(0xFF009688), // turkuaz
|
||||
Color(0xFF2196F3), // mavi
|
||||
Color(0xFF9C27B0), // mor
|
||||
Color(0xFFE91E63), // pembe
|
||||
];
|
||||
|
||||
static final ValueNotifier<Color> notifier =
|
||||
ValueNotifier<Color>(Color(WindowPersistence.hoverColor));
|
||||
|
||||
static void set(Color color) {
|
||||
notifier.value = color;
|
||||
WindowPersistence.saveHoverColor(color.toARGB32());
|
||||
}
|
||||
}
|
||||
@@ -25,6 +25,11 @@ class WindowPersistence {
|
||||
/// Sadece modu günceller; x/y/w/h korunur.
|
||||
static void saveFilled(bool value) => _write({'filled': value});
|
||||
|
||||
/// Tüm arayüzdeki hover vurgu rengi (ARGB). Anahtar yoksa varsayılan kırmızı.
|
||||
static int get hoverColor => (_read()?['hoverColor'] as num?)?.toInt() ?? 0xFFF44336;
|
||||
|
||||
static void saveHoverColor(int value) => _write({'hoverColor': value});
|
||||
|
||||
/// Save window rect synchronously (safe to call before destroy).
|
||||
static void saveSync({
|
||||
required Offset position,
|
||||
|
||||
Reference in new issue
Block a user