Seit mir meine HDD eingegangen ist, greife ich wieder auf das vorinstallierte Vista zurück, vermisste aber meine Leiste. Daher: TopBar bringt die Ubuntu-Leiste auf den Windows-Screen!
Es ist nicht für die Öffentlichkeit programiert, daher alles auf meinen PC ausgelegt. Sollte aber auch funktionieren.
Damit die Bar immer ganz oben ist und nicht eure Fensterleisten überdeckt, erstellt ihr einfach einen Ordner und zieht ihn ans öbere Bildschirmende. Dann noch Rechtsklick->immer im Vordergrund
Starmenü darf nciht Klassisch sein! (Ändern in Rechtsklick auf Taskleiste->einstellungen-> Startmenu-> (_)Startmenu
Dann einfach start.exe starten! (Für die Selbstcompilierer: Die Programmnamen MÜSSEN Apps.exe und TopBar.exe heißen, start.exe ist wurscht!)
Die Display.exe ist ausm Internet, und ist zum Bildschirm-Ausschaulten Bein [0ff]->Lock Screen
ToDo: Places-Button befüllen (momentan about:blank) und das Programm ins Deutsche übersetzten.
Grüße, Tobias
Zip zu groß, daher extern: http://ul.to/lht5pm
Ubuntu-Topbar für Windows
-
-
Hier noch mal der Code zum Durchlesen und in Deutsch und ein paar Screens:
Apps.au3
[autoit]#NoTrayIcon
[/autoit] [autoit][/autoit] [autoit]
#include <includes.au3>
$startmenu = WinGetHandle ("[CLASS:DV2ControlHost]")$main = GUICreate ("TopBar-Apps", 115, 36, 0, 0, 0x80000000, 0x00000080, WinGetHandle ("TopBar", "System]"))
[/autoit] [autoit][/autoit] [autoit]
$hImage = _GUIImageList_Create(30, 30, 5, 3, 6)
_GUIImageList_AddIcon($hImage, "shell32.dll", 130, True)
;~ _GUIImageList_AddIcon($hImage, "shell32.dll", 212, True); hover image
$apps = GUICtrlCreateButton("Anwendungen", 3, 3, 110, 31)
_GUICtrlButton_SetImageList ($apps, $hImage)
GUISetState (@SW_SHOW, $main)While 1
[/autoit] [autoit][/autoit] [autoit]
Switch GUIGetMsg ()
Case $apps
_appsgui ()
EndSwitch
If WinActive ($startmenu) Then
While WinActive ($startmenu)
WEnd
Exit 0
EndIf
WEnd##Script written by Tobias Girstmair##
[/autoit]
Func _appsgui () ;show startmenu as apps menu
WinMove ($startmenu, "", 0, 36, 268, 508-30)
WinSetState ($startmenu, "", @SW_SHOW)
ControlShow ($startmenu, "", "[CLASS:SysListView32; INSTANCE:1]")
ControlShow ($startmenu, "", "[CLASS:DesktopSFTBarHost; INSTANCE:1]")
ControlShow ($startmenu, "", "[CLASS:Desktop More Programs Pane; INSTANCE:1]")
ControlShow ($startmenu, "", "[CLASS:Desktop Open Pane Host; INSTANCE:1]")
ControlShow ($startmenu, "", "[CLASS:Desktop OpenBox Host; INSTANCE:1]")
;~ ControlClick ($startmenu, "", "[CLASS:Button; INSTANCE:1]")
EndFuncTopbar.au3
[autoit]#Region header
[/autoit] [autoit][/autoit] [autoit]
#NoTrayIcon
#include <includes.au3>
#include <IE.au3>
$o_IE_system = _IECreateEmbedded ()
$o_IE_places = _IECreateEmbedded ()
Global $off_enabled = 0
Global $date_enabled= 0
Global $system_enabled = 0
Global $places_enabled = 0
Global $time = @hour & ":" & @min & ":" & @sec & "; " & @mday & "." & @mon & "." & @year
$i_places = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_places, "shell32.dll", 28, True);MITTIG!!!!
$i_system = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_system, "shell32.dll", 21, True)
$i_net = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_net, @ProgramFilesDir & "\Mozilla Firefox\firefox.exe", 0, True)
$i_mail = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_mail, @ProgramFilesDir & "\Windows Mail\WinMail.exe", 1, True)
$i_term = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_term, @SystemDir & "\cmd.exe", 0, True)
$i_off = _GUIImageList_Create(28, 28, 5, 3, 6)
_GUIImageList_AddIcon($i_off, "shell32.dll", 27, True)#EndRegion header
[/autoit] [autoit][/autoit] [autoit]#Region GUIs
[/autoit] [autoit][/autoit] [autoit]
#Region maingui
$main = GUICreate ("TopBar", @desktopwidth-225+113, 36, 0+225-110, 0, 0x80000000, 0x00000080, WinGetHandle ("[CLASS:BaseBar]"))
$b_places = GUICtrlCreateButton ("Orte", 1, 3, 110, 31)
_GUICtrlButton_SetImageList ($b_places, $i_places, 4, 1, 7)
$b_system = GUICtrlCreateButton ("System", 223-222+113, 3, 110, 31); (not yet set)
_GUICtrlButton_SetImageList ($b_system, $i_system)
$b_net = GUICtrlCreateButton ("Firefox", 336-222+113, 3, 31, 31, 0x8000+0x0040)
_GUICtrlButton_SetImageList ($b_net, $i_net, 4)
;~ GUICtrlSetImage ($b_net, @ProgramFilesDir & "\Mozilla Firefox\firefox.exe", 1)
$b_mail = GUICtrlCreateButton ("Empathy", 367-222+113, 3, 31, 31, 0x8000+0x0040)
_GUICtrlButton_SetImageList ($b_mail, $i_mail, 4)
;~ GUICtrlSetImage ($b_mail, @ProgramFilesDir & "\Windows Mail\WinMail.exe", 1)
$b_term = GUICtrlCreateButton ("Terminal", 398-222+113, 3, 31, 31, 0x8000+0x0040)
_GUICtrlButton_SetImageList ($b_term, $i_term, 4)
;~ GUICtrlSetImage ($b_term, @SystemDir & "\cmd.exe", 1)
$b_date = GUICtrlCreateButton ($time, @desktopwidth-200-222+113, 3, 160, 31)
GUICtrlSetFont ($b_date, 8.5, 800)
$b_off = GUICtrlCreateButton (@UserName, @DesktopWidth-34-222+110, 3, 31, 31, 0x8000+0x0040)
_GUICtrlButton_SetImageList ($b_off, $i_off, 4)
;~ GUICtrlSetImage ($b_off, @SystemDir & "\shell32.dll", 28)
GUISetState (@SW_SHOW, $main)
;~ GUICtrlCreateLabel ("move", 900, 3, 100, 100, -1, 0x00100000)
#EndRegion maingui#Region subcats
[/autoit] [autoit][/autoit] [autoit]
$g_off = GUICreate ("Topbar-Shutdown", 150, 84, @DesktopWidth-150, 36, 0x80000000, 0x00000080)
$b_off_lock = GUICtrlCreateButton ("Bildschirm sperren", 1, 1, 148, 20)
$b_off_standby = GUICtrlCreateButton ("Standby", 1, 21, 148, 20)
$b_off_logoff = GUICtrlCreateButton ("Abmelden", 1, 42, 148, 20)
$b_off_off = GUICtrlCreateButton ("Herunterfahren", 1, 63, 148, 20)
$g_date = GUICreate ("Topbar-Date", 177, 160, @DesktopWidth-200, 36, 0x80000000, 0x00000080)
GUICtrlCreateMonthCal ("Today: ", -2, -2)
GUICtrlCreateLabel ("Calendar4TopBar", 10, 10, 0, 0)
$g_system = GUICreate ("system4topbar", 150, 380, 227, 36, 0x80000000, 0x00000080)
GUICtrlCreateObj ($o_IE_system, 0, 0, 150, 380)
GUICtrlCreateLabel ("System4TopBar", 0, 0, 0, 0)
_IENavigate ($o_IE_system, "shell:ControlPanelFolder", 0)
$g_places = GUICreate ("places4topbar", 150, 380, 117, 36, 0x80000000, 0x00000080)
GUICtrlCreateObj ($o_IE_places, 0, 0, 150, 380)
GUICtrlCreateLabel ("Places4TopBar", 0, 0, 0, 0)
_IENavigate ($o_IE_places, "about:blank", 0);_shell:desktop", 0)
#EndRegion subcats
#EndRegion GUIs#Region loop
[/autoit] [autoit][/autoit] [autoit]
While 1
Switch GUIGetMsg ()
Case $b_places
_placesgui ()
Case $b_system
_systemgui ()
Case $b_net
Run (@ProgramFilesDir & "\Mozilla Firefox\firefox.exe")
Case $b_mail
Run (@ProgramFilesDir & "\Windows Mail\WinMail.exe")
Case $b_term
Run (@SystemDir & "\cmd.exe")
Case $b_off
_shutdowngui ()
Case $b_date
_dategui ()
Case $b_off_lock
Run(@ComSpec & " /C " & "%windir%\System32\rundll32.exe user32.dll,LockWorkStation", "", @SW_HIDE)
Run (@ComSpec & " /C " & @ScriptDir & "\display /power:off", "", @SW_HIDE)
Case $b_off_standby
Shutdown (32)
Case $b_off_logoff
Shutdown (0)
Case $b_off_off
Shutdown (1)
EndSwitch
If $time <> @hour & ":" & @min & ":" & @sec & "; " & @mday & "." & @mon & "." & @year Then ;reload time
$time = @hour & ":" & @min & ":" & @sec & "; " & @mday & "." & @mon & "." & @year
GUICtrlSetData ($b_date, $time)
EndIf
If $off_enabled = 1 And WinActive ("", "Herunterfahren") = 0 Then
_shutdowngui ()
EndIf
If $date_enabled = 1 And WinActive ("", "Calendar4TopBar") = 0 Then
_dategui ()
EndIf
If $system_enabled = 1 And WinActive ("", "System4TopBar") = 0 Then
_systemgui ()
EndIf
If $places_enabled = 1 And WinActive ("", "Places4TopBar") = 0 Then
_placesgui ()
EndIf
WEnd
#EndRegion loop##Script written by Tobias Girstmair##
[/autoit] [autoit][/autoit] [autoit]
#Region functions
Func _shutdowngui () ;switch submenus
If $off_enabled = 1 Then
GUISetState (@SW_HIDE, $g_off)
$off_enabled = 0
Else
GUISetState (@SW_SHOW, $g_off)
$off_enabled = 1
GUISetState (@SW_HIDE, $g_date)
$date_enabled= 0
GUISetState (@SW_HIDE, $g_system)
$system_enabled = 0
GUISetState (@SW_HIDE, $g_places)
$places_enabled = 0
EndIf
EndFuncFunc _dategui () ;switch submenus
[/autoit] [autoit][/autoit] [autoit]
If $date_enabled = 1 Then
GUISetState (@SW_HIDE, $g_date)
$date_enabled = 0
Else
GUISetState (@SW_SHOW, $g_date)
$date_enabled= 1
GUISetState (@SW_HIDE, $g_off)
$off_enabled = 0
GUISetState (@SW_HIDE, $g_system)
$system_enabled = 0
GUISetState (@SW_HIDE, $g_places)
$places_enabled = 0
EndIf
EndFuncFunc _systemgui () ;switch submenus
[/autoit] [autoit][/autoit] [autoit]
If $system_enabled = 1 Then
GUISetState (@SW_HIDE, $g_system)
$system_enabled = 0
Else
GUISetState (@SW_HIDE, $g_date)
$date_enabled= 0
GUISetState (@SW_HIDE, $g_off)
$off_enabled = 0
GUISetState (@SW_HIDE, $g_places)
$places_enabled = 0
GUISetState (@SW_SHOW, $g_system)
$system_enabled = 1
EndIf
EndFuncFunc _placesgui () ;switch submenus
[/autoit]
If $places_enabled = 1 Then
GUISetState (@SW_HIDE, $g_places)
$places_enabled = 0
Else
GUISetState (@SW_HIDE, $g_date)
$date_enabled= 0
GUISetState (@SW_HIDE, $g_off)
$off_enabled = 0
GUISetState (@SW_SHOW, $g_places)
$places_enabled = 1
GUISetState (@SW_HIDE, $g_system)
$system_enabled = 0
EndIf
EndFuncstart.au3
[autoit]WinSetTrans ("[CLASS:BaseBar]", "", 0) ;original Topbar + schatten entfernen
[/autoit] [autoit][/autoit] [autoit]
TraySetIcon (@systemdir & "\shell32.dll", -35)
Opt("TrayOnEventMode",1)
Opt("TrayMenuMode",1) ; Default tray menu items (Script Paused/Exit) will not be shown.$exit = TrayCreateItem("Beenden")
[/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]
TrayItemSetOnEvent(-1,"autoitexit")
TraySetState()
Run ("TopBar.exe")
Run ("Apps.exe")
While Not WinExists ("TopBar-Apps", "Applications")
Sleep (10)
WEnd
Send ("{Lwin}") ;Startmenue einmal aufrufen, um darstellungsprobleme zu verhindern ;;;;DIESE PASSAGE IST DERZEIT
MouseClick ("left", 20, @DesktopHeight-20, 1) ;;;;NOCH NICHT FERNIG! VORSCHLAEGE?
While 1
Sleep (10)
If Not ProcessExists ("Apps.exe") Then Run ("Apps.exe")
If Not ProcessExists ("TopBar.exe") Then Run ("TopBar.exe")
WEnd##Script written by Tobias Girstmair##
[/autoit] [autoit][/autoit] [autoit]
Func _1 ()
While ProcessExists ("Apps.exe")
ProcessClose ("Apps.exe")
WEnd
While ProcessExists ("TopBar.exe")
ProcessClose ("TopBar.exe")
WEnd
EndFuncFunc autoitexit ();exit script
[/autoit]
If MsgBox (48+4, "Warnung!", "TopBar beenden?") = 6 Then
WinSetTrans ("[CLASS:BaseBar]", "", 255)
WinSetState (WinGetHandle ("[CLASS:DV2ControlHost]"), "", @SW_SHOW)
_1 ()
Exit 0
EndIf
EndFuncScreens
In der nächsten Version:- INI bzw. Ordner für Schnellstart
- start.au3 -> Zeile 14-15 verbessern