clapp-pm 1.0.44__py3-none-any.whl → 1.0.46__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. {clapp_pm-1.0.44.data → clapp_pm-1.0.46.data}/data/version.json +1 -1
  2. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/METADATA +1 -1
  3. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/RECORD +13 -29
  4. manifest_schema.py +1 -1
  5. manifest_validator.py +1 -1
  6. package_runner.py +1 -0
  7. packages/luaozgur-moba/README.md +159 -0
  8. packages/luaozgur-moba/manifest.json +8 -0
  9. version.py +1 -1
  10. packages/pycloudos/README.md +0 -279
  11. packages/pycloudos/core/appmon.py +0 -0
  12. packages/pycloudos/main.py +0 -193
  13. packages/pycloudos/manifest.json +0 -15
  14. packages/pycloudos/rain/__init__.py +0 -7
  15. packages/pycloudos/rain/contextmenu.py +0 -1370
  16. packages/pycloudos/rain/desktop.py +0 -556
  17. packages/pycloudos/rain/dock.py +0 -722
  18. packages/pycloudos/rain/flet_html_widgets.py +0 -1448
  19. packages/pycloudos/rain/theme.py +0 -930
  20. packages/pycloudos/rain/topbar.py +0 -1421
  21. packages/pycloudos/rain/ui.py +0 -381
  22. packages/pycloudos/rain/wallpaper.py +0 -830
  23. packages/pycloudos/rain/widgets.py +0 -688
  24. packages/pycloudos/rain/windowmanager.py +0 -605
  25. packages/pycloudos/requirements-dev.txt +0 -43
  26. packages/pycloudos/requirements.txt +0 -43
  27. packages/pycloudos/setup_deps.py +0 -422
  28. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/WHEEL +0 -0
  29. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/entry_points.txt +0 -0
  30. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/licenses/LICENSE +0 -0
  31. {clapp_pm-1.0.44.dist-info → clapp_pm-1.0.46.dist-info}/top_level.txt +0 -0
@@ -1,381 +0,0 @@
1
- """
2
- Rain UI - Ana Arayüz Sistemi
3
- PyCloud OS için macOS Aqua stilinde masaüstü ortamı
4
- """
5
-
6
- import sys
7
- import logging
8
- from typing import Optional
9
-
10
- try:
11
- from PyQt6.QtWidgets import (QApplication, QMainWindow, QWidget, QVBoxLayout,
12
- QHBoxLayout, QLabel, QPushButton, QScrollArea,
13
- QFrame, QTextEdit, QListWidget, QListWidgetItem, QSystemTrayIcon, QMenu)
14
- from PyQt6.QtCore import Qt, QTimer, pyqtSignal, QRect
15
- from PyQt6.QtGui import QFont, QPixmap, QPainter, QBrush, QPen, QIcon, QPalette, QColor
16
- from rain.topbar import RainTopbar
17
- PYQT_AVAILABLE = True
18
- except ImportError as e:
19
- print(f"PyQt6 veya bağımlılıkları yüklenemedi: {e}")
20
- PYQT_AVAILABLE = False
21
- # Mock classes for testing
22
- class QApplication: pass
23
- class QMainWindow: pass
24
- class QWidget: pass
25
- class RainTopbar: pass
26
-
27
- class RainUI:
28
- """Rain UI ana sınıfı"""
29
-
30
- def __init__(self, kernel):
31
- self.logger = logging.getLogger("RainUI")
32
- self.kernel = kernel
33
- self.app: Optional[QApplication] = None
34
- self.main_window: Optional[QMainWindow] = None
35
-
36
- # PyQt6 durum kontrolü
37
- self.logger.info(f"PyQt6 available: {PYQT_AVAILABLE}")
38
-
39
- if not PYQT_AVAILABLE:
40
- self.logger.error("PyQt6 not available, UI will not start")
41
- return
42
-
43
- try:
44
- self.initialize()
45
- self.logger.info("RainUI constructor completed successfully")
46
- except Exception as e:
47
- self.logger.error(f"RainUI initialization failed: {e}")
48
- import traceback
49
- self.logger.error(traceback.format_exc())
50
-
51
- def initialize(self):
52
- """UI sistemini başlat"""
53
- try:
54
- # QApplication kontrol et (eğer yoksa oluştur)
55
- self.app = QApplication.instance()
56
- if self.app is None:
57
- self.app = QApplication(sys.argv)
58
- self.app.setApplicationName("PyCloud OS")
59
- self.app.setApplicationVersion("0.9.0-dev")
60
-
61
- # Ana pencereyi oluştur
62
- self.main_window = RainMainWindow(self.kernel)
63
-
64
- # Tema uygula
65
- self.apply_theme()
66
-
67
- self.logger.info("Rain UI initialized")
68
-
69
- except Exception as e:
70
- self.logger.error(f"Failed to initialize Rain UI: {e}")
71
- raise
72
-
73
- def apply_theme(self):
74
- """Tema uygula"""
75
- try:
76
- # Temel tema ayarları
77
- palette = QPalette()
78
-
79
- # Koyu tema (varsayılan)
80
- palette.setColor(QPalette.ColorRole.Window, QColor(45, 45, 45))
81
- palette.setColor(QPalette.ColorRole.WindowText, QColor(255, 255, 255))
82
- palette.setColor(QPalette.ColorRole.Base, QColor(35, 35, 35))
83
- palette.setColor(QPalette.ColorRole.AlternateBase, QColor(53, 53, 53))
84
- palette.setColor(QPalette.ColorRole.ToolTipBase, QColor(0, 0, 0))
85
- palette.setColor(QPalette.ColorRole.ToolTipText, QColor(255, 255, 255))
86
- palette.setColor(QPalette.ColorRole.Text, QColor(255, 255, 255))
87
- palette.setColor(QPalette.ColorRole.Button, QColor(53, 53, 53))
88
- palette.setColor(QPalette.ColorRole.ButtonText, QColor(255, 255, 255))
89
- palette.setColor(QPalette.ColorRole.BrightText, QColor(255, 0, 0))
90
- palette.setColor(QPalette.ColorRole.Link, QColor(42, 130, 218))
91
- palette.setColor(QPalette.ColorRole.Highlight, QColor(42, 130, 218))
92
- palette.setColor(QPalette.ColorRole.HighlightedText, QColor(0, 0, 0))
93
-
94
- self.app.setPalette(palette)
95
-
96
- # CSS stilleri
97
- style = """
98
- QMainWindow {
99
- background-color: #2d2d2d;
100
- color: #ffffff;
101
- }
102
-
103
- QWidget {
104
- background-color: #2d2d2d;
105
- color: #ffffff;
106
- font-family: 'Arial', 'Helvetica', sans-serif;
107
- font-size: 13px;
108
- border: none;
109
- }
110
-
111
- QPushButton {
112
- background-color: #404040;
113
- border: 1px solid #555555;
114
- border-radius: 6px;
115
- padding: 8px 16px;
116
- color: #ffffff;
117
- }
118
-
119
- QPushButton:hover {
120
- background-color: #4a4a4a;
121
- border-color: #666666;
122
- }
123
-
124
- QPushButton:pressed {
125
- background-color: #363636;
126
- }
127
-
128
- QLabel {
129
- color: #ffffff;
130
- background-color: transparent;
131
- }
132
-
133
- /* Monospace text areas */
134
- QTextEdit, QPlainTextEdit {
135
- font-family: 'Courier', 'Consolas', monospace;
136
- }
137
- """
138
-
139
- self.app.setStyleSheet(style)
140
-
141
- except Exception as e:
142
- self.logger.error(f"Failed to apply theme: {e}")
143
-
144
- def show(self):
145
- """Ana pencereyi göster"""
146
- if not PYQT_AVAILABLE or not self.main_window:
147
- self.logger.error("Cannot show UI: PyQt6 not available or not initialized")
148
- return
149
-
150
- try:
151
- self.main_window.show()
152
- self.logger.info("Rain UI shown")
153
- except Exception as e:
154
- self.logger.error(f"Failed to show UI: {e}")
155
-
156
- def run(self) -> int:
157
- """UI ana döngüsünü başlat"""
158
- if not PYQT_AVAILABLE or not self.app:
159
- self.logger.error("Cannot run UI: PyQt6 not available or not initialized")
160
- return 1
161
-
162
- try:
163
- # Ana pencereyi göster
164
- if self.main_window:
165
- self.main_window.show()
166
-
167
- # Event loop'u başlat
168
- return self.app.exec()
169
-
170
- except Exception as e:
171
- self.logger.error(f"UI run error: {e}")
172
- return 1
173
-
174
- def shutdown(self):
175
- """UI sistemini kapat"""
176
- if self.app:
177
- self.app.quit()
178
- self.logger.info("Rain UI shutdown")
179
-
180
- class RainMainWindow(QMainWindow):
181
- """Ana pencere sınıfı"""
182
-
183
- def __init__(self, kernel):
184
- super().__init__()
185
- self.kernel = kernel
186
- self.logger = logging.getLogger("RainMainWindow")
187
-
188
- self.setup_ui()
189
- self.setup_connections()
190
-
191
- def setup_ui(self):
192
- """Arayüzü kur"""
193
- self.setWindowTitle("PyCloud OS")
194
- self.setGeometry(100, 100, 1200, 800)
195
-
196
- # Ana widget
197
- main_widget = QWidget()
198
- self.setCentralWidget(main_widget)
199
-
200
- # Wallpaper'ı ana widget'a uygula
201
- self.apply_wallpaper_to_main_widget(main_widget)
202
-
203
- # Ana layout
204
- main_layout = QVBoxLayout(main_widget)
205
- main_layout.setContentsMargins(0, 0, 0, 0)
206
- main_layout.setSpacing(0)
207
-
208
- # Topbar oluştur ve ekle
209
- self.topbar = RainTopbar(self.kernel)
210
- main_layout.addWidget(self.topbar)
211
-
212
- # Desktop oluştur (window manager da burada başlatılır)
213
- self.create_desktop(main_layout)
214
-
215
- # Topbar ve window manager entegrasyonunu kur
216
- if hasattr(self, 'window_manager') and self.window_manager:
217
- self.window_manager.set_topbar(self.topbar)
218
- self.logger.info("Topbar-WindowManager integration established")
219
-
220
- # Dock oluştur
221
- self.create_dock(main_layout)
222
-
223
- # UI hazır olduktan sonra timer'ları başlat
224
- QTimer.singleShot(100, self.topbar.setup_timer)
225
-
226
- self.logger.info("Rain UI initialized")
227
-
228
- def apply_wallpaper_to_main_widget(self, main_widget):
229
- """Ana widget'a wallpaper uygula"""
230
- try:
231
- # Wallpaper manager'dan mevcut wallpaper'ı al
232
- default_background = "#2d2d2d"
233
- background_image = ""
234
-
235
- if self.kernel:
236
- wallpaper_manager = self.kernel.get_module("wallpaper")
237
- if wallpaper_manager and wallpaper_manager.config.current_path:
238
- import os
239
- if os.path.exists(wallpaper_manager.config.current_path):
240
- background_image = f"background-image: url('{wallpaper_manager.config.current_path}');"
241
-
242
- # Ana widget'a wallpaper uygula - dock'un altına kadar iner
243
- main_widget.setStyleSheet(f"""
244
- QWidget {{
245
- background-color: {default_background};
246
- {background_image}
247
- background-repeat: no-repeat;
248
- background-position: center;
249
- }}
250
- """)
251
-
252
- except Exception as e:
253
- self.logger.error(f"Failed to apply wallpaper: {e}")
254
-
255
- def create_topbar(self, parent_layout):
256
- """Topbar oluştur"""
257
- try:
258
- from rain.topbar import RainTopbar
259
- self.topbar = RainTopbar(self.kernel)
260
- parent_layout.addWidget(self.topbar)
261
- except ImportError:
262
- # Basit topbar
263
- topbar = QWidget()
264
- topbar.setFixedHeight(30)
265
- topbar.setStyleSheet("background-color: #1e1e1e; border-bottom: 1px solid #404040;")
266
- parent_layout.addWidget(topbar)
267
- self.logger.warning("Using simple topbar (rain.topbar not available)")
268
-
269
- def create_desktop(self, parent_layout):
270
- """Desktop alanı oluştur"""
271
- try:
272
- # Window Manager'ı başlat
273
- from rain.windowmanager import init_window_manager
274
- self.window_manager = init_window_manager(self.kernel)
275
- self.kernel.register_module("windowmanager", self.window_manager)
276
-
277
- # Desktop widget'ını oluştur
278
- try:
279
- from rain.desktop import RainDesktop
280
- self.desktop = RainDesktop(self.kernel)
281
-
282
- # Ana desktop container - artık saydam
283
- desktop_container = QWidget()
284
-
285
- # Desktop container saydam olsun, wallpaper ana widget'ta
286
- desktop_container.setStyleSheet("""
287
- QWidget {
288
- background-color: transparent;
289
- }
290
- """)
291
-
292
- # Stacked layout - desktop üstte, MDI area gizli
293
- from PyQt6.QtWidgets import QStackedLayout
294
- desktop_layout = QStackedLayout(desktop_container)
295
- desktop_layout.setContentsMargins(0, 0, 0, 0)
296
-
297
- # Desktop widget'ını ana sayfa olarak ekle
298
- desktop_layout.addWidget(self.desktop)
299
-
300
- # MDI area'yı ikinci sayfa olarak ekle (gizli)
301
- mdi_area = self.window_manager.get_mdi_area()
302
- if mdi_area:
303
- mdi_area.setStyleSheet("""
304
- QMdiArea {
305
- background-color: transparent;
306
- border: none;
307
- }
308
- """)
309
- desktop_layout.addWidget(mdi_area)
310
-
311
- # Window manager'a desktop container referansını ver
312
- self.window_manager.desktop_container = desktop_container
313
- self.window_manager.desktop_layout = desktop_layout
314
- self.window_manager.show_desktop = lambda: desktop_layout.setCurrentIndex(0)
315
- self.window_manager.show_windows = lambda: desktop_layout.setCurrentIndex(1)
316
-
317
- # Desktop'u varsayılan olarak göster
318
- desktop_layout.setCurrentIndex(0)
319
-
320
- # Desktop container'ı parent layout'a ekle - dock'tan önce
321
- parent_layout.addWidget(desktop_container)
322
-
323
- # Kernel'a desktop referansını ver
324
- self.kernel.register_module("desktop", self.desktop)
325
-
326
- self.logger.info("Desktop created successfully")
327
-
328
- except ImportError:
329
- # Basit desktop
330
- simple_desktop = QWidget()
331
- simple_desktop.setStyleSheet("background-color: #2d2d2d;")
332
- parent_layout.addWidget(simple_desktop)
333
- self.logger.warning("Using simple desktop (rain.desktop not available)")
334
-
335
- except ImportError:
336
- # Window manager yok, basit desktop
337
- simple_desktop = QWidget()
338
- simple_desktop.setStyleSheet("background-color: #2d2d2d;")
339
- parent_layout.addWidget(simple_desktop)
340
- self.logger.warning("Using simple desktop (rain.windowmanager not available)")
341
-
342
- def create_dock(self, parent_layout):
343
- """Dock oluştur"""
344
- try:
345
- from rain.dock import ModernDock
346
- self.dock = ModernDock(self.kernel)
347
- parent_layout.addWidget(self.dock)
348
- except ImportError:
349
- # Basit dock
350
- dock = QWidget()
351
- dock.setFixedHeight(60)
352
- dock.setStyleSheet("background-color: #1e1e1e; border-top: 1px solid #404040;")
353
- parent_layout.addWidget(dock)
354
- self.logger.warning("Using simple dock (rain.dock not available)")
355
-
356
- def setup_connections(self):
357
- """Sinyal bağlantılarını kur"""
358
- # Kernel olaylarını dinle
359
- try:
360
- from core.events import subscribe, SystemEvents
361
- subscribe(SystemEvents.SYSTEM_SHUTDOWN, self.on_system_shutdown)
362
- subscribe(SystemEvents.THEME_CHANGE, self.on_theme_change)
363
- except ImportError:
364
- self.logger.warning("Event system not available")
365
-
366
- def on_system_shutdown(self, event):
367
- """Sistem kapatma olayı"""
368
- self.close()
369
-
370
- def on_theme_change(self, event):
371
- """Tema değişikliği olayı"""
372
- # Temayı yeniden uygula
373
- if hasattr(self.parent(), 'apply_theme'):
374
- self.parent().apply_theme()
375
-
376
- def closeEvent(self, event):
377
- """Pencere kapatma olayı"""
378
- # Kernel'e kapatma sinyali gönder
379
- if self.kernel:
380
- self.kernel.shutdown()
381
- event.accept()