Decipher Posted April 3, 2013 Share Posted April 3, 2013 (edited) I started this a couple of months ago and figured that maybe others would like to contribute or just criticize whatever does it for you. I'm having to start from scratch and re-research everything but if someone has some code to contribute or ideas please share them. Everyone else start coding like freaking crazy. For those lost on the subject please lookup emerge desktop as some of it may be incorporated into this version. It won't be if I can help it though. To get some conversation started what features are the most desired? Should (AutoIt Desktop Shell) be the name? Ideas? Registering the shell is simple enough - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\Shell I will be needing to touch on some sensitive subjects. How can we intercept the same hotkeys as explorer for the start menu and etc... If this is unacceptable then mods please due inform me. I'm not asking now, just speculating on this project's development. Edited April 3, 2013 by Decipher Spoiler Link to comment Share on other sites More sharing options...
Decipher Posted April 3, 2013 Author Share Posted April 3, 2013 (edited) AutoIt Desktop Shell Source - Updated 9:33 PM 4/2/2013I've started writting some startup functions.expandcollapse popup#NoTrayIcon #include <File.au3> #include <Array.au3> Global Const $sDEF_SETTINGS_PATH = @ScriptDir & "\Settings.ini" Global Const $sDEF_STARTUP_DIR = @StartupDir ;- Currently only reads from current users startup directory. ;- Not currently implemented - Global Const $sDEF_STARTUP_EXCLUDE = False ;- This code is extremely experimental and only displays information ;- TODO: ; (1) Add other special folder startup location - I think whatever is register under HKLM->RUN will still start but haven't tested it. ;(2) Add option to exclude default locations along with option to include a custom startup location ;(3) Add option for delays and pherhaps order based on the order the user has entered in the settings file. ;(4) Open to suggestions - This is a couple of many function to be written to create the AutoIt Desktop Shell Global $aStartupPID[50] Dim $aList = _GetStartupList() ;- _ArrayDisplay($aList) _ExecuteStartupList($aList) Func _GetStartupDir($sStartupDir = $sDEF_STARTUP_DIR) Local $sSetting = IniRead(@ScriptDir & "\settings.ini", "LoadAtStartup", "StartupDir", "") If Not $sSetting Then $sSetting = $sStartupDir EndIf Return $sSetting EndFunc Func _GetStartupList($sExcludeList = "") Local $aExcludeList , $sStartupList, $aStartupList = _FileListToArray(_GetStartupDir(), "*", 0) If @error Then Return @error EndIf $sExcludeList = "desktop.ini," & IniRead($sDEF_SETTINGS_PATH, "LoadAtStartup", "Exclude", "") If StringInStr($sExcludeList, ",", 2, -1) == StringLen($sExcludeList) Then $sExcludeList = StringTrimRight($sExcludeList, 1) EndIf $aExcludeList = StringSplit($sExcludeList, ",") For $i = 1 To $aStartupList[0] Step 1 For $index = 1 To $aExcludeList[0] Step 1 If Not StringInStr($aStartupList[$i], $aExcludeList[$index], 2) Then $sStartupList &= $aStartupList[$i] & "," EndIf Next Next Return StringSplit(StringTrimRight($sStartupList, 1), ",") EndFunc Func _IsFileShortcut($sFilename) Local $szDrive, $szDir, $szFName, $szExt Local $aPath = _PathSplit($sFilename, $szDrive, $szDir, $szFName, $szExt) If $aPath[4] == ".lnk" Then Return True EndIf EndFunc Func _ExecuteStartupList($aStartupList) Local $aProperties, $sStartupDir = _GetStartupDir() For $i = 1 To $aStartupList[0] Step 1 If _IsFileShortcut($aStartupList[$i]) Then $aProperties = FileGetShortcut(_PathFull($aStartupList[$i], $sStartupDir)) If Not @error Then ;- Run($aProperties[0], $aProperties[1], $aProperties[6]) ConsoleWrite("Run(" & $aProperties[0] & ", " & $aProperties[1] & ", " & $aProperties[6] & ")" & @CRLF) EndIf Else ;- Run($aStartupList[$i], $sStartupDir) ConsoleWrite("Run(" & $aStartupList[$i] & ")" & @CRLF) EndIf Next EndFunc - This would be preferred since .lnk usually are executed by explorer but some function may have to be reponsible for retrieving the specific icon for a shortcut. - This will be used in the desktop window functions.Multiple Desktops - Wow! I see now that most of the work has already been done and there isn't any reason to reinvent the wheel here but I may need to contact the author of this - This will work great for showing the default menus when a user right clicks on a icon in the program manager. - Easy on the eyes and has made the cut - This will be a feature.Any of the authors of the fore-mentioned scripts that wish for their work not to be included partly or entirely into this project then please PM me and I will make the necessary changes. Edited April 3, 2013 by Decipher Spoiler Link to comment Share on other sites More sharing options...
James Posted April 3, 2013 Share Posted April 3, 2013 (edited) This has been done before, have a search, there was a guy called JustinReno, BrettF and myself who I distinctly remember taking part in.Edit: Here they are.BrettF - seclinix - JustinReno - Alek - Dhilip89 - And I can't seem to find mine anymore, I'm sure I made one though... Edited April 3, 2013 by James Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted April 3, 2013 Moderators Share Posted April 3, 2013 Also, as this is not specifically asking for assistance to resolve an issue, but presenting an idea for people to contribute to, perhaps the Example Scripts section would be more appropriate. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Decipher Posted April 3, 2013 Author Share Posted April 3, 2013 (edited) How can I register a listener function for the Win+R Hotkey? The program manager will need to take use of the settings in this location: HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics expandcollapse popup#NoTrayIcon #include <WindowsConstants.au3> #include <GUIConstantsEx.au3> #Include <Misc.au3> Global Const $sDEF_WALLPAPER = RegRead("HKEY_CURRENT_USER\Control Panel\Desktop", "Wallpaper") Global Const $iDEF_TASKBAR_SIZE = 22 ;- Toolbar at top of screen Global $hProgMan, $aDesktopIcon[1][2];- $aDesktopIcon[50][2] _ProgMan_Start() Func _ProgMan_Start() $hProgMan = GUICreate("ProgMan", @DesktopWidth, @DesktopHeight, -1, -1, $WS_POPUP) $hCtrl_Background = GUICtrlCreatePic($sDEF_WALLPAPER, -1, $iDEF_TASKBAR_SIZE, @DesktopWidth, @DesktopHeight-$iDEF_TASKBAR_SIZE) GUICtrlSetState($hCtrl_Background, @SW_DISABLE) $aDesktopIcon[0][0] = GUICtrlCreateIcon("H:\Windows\System32\notepad.exe", -1, -1, -1) $aDesktopIcon[0][1] = ControlGetPos($hProgMan, "", $aDesktopIcon[0][0]) ;_ProgMan_Icons() GUISetState(@SW_SHOWNA) EndFunc Func _ProgMan_Icons() ;_WinAPI_ExtractIconEx( EndFunc While 1 $iMsg = GUIGetMsg() If $iMsg == $GUI_EVENT_SECONDARYUP Then Exit _ProgMan_MoveIcon() WEnd Func _ProgMan_MoveIcon() If _IsPressed("01") Then Opt("MouseCoordMode", 2) Local $aMPosNew, $aCtrlPos, $aMousePos = MouseGetPos() For $i = 0 To UBound($aDesktopIcon, 1) -1 Step 1 $aCtrlPos = $aDesktopIcon[$i][1] If $aMousePos[0] >= $aCtrlPos[0] And $aMousePos[0] <= ($aCtrlPos[0] + $aCtrlPos[2]) _ And $aMousePos[1] >= $aCtrlPos[1] And $aMousePos[1] <= ($aCtrlPos[1] + $aCtrlPos[3]) Then Do $aMPosNew = MouseGetPos() ControlMove($hProgMan, "", $aDesktopIcon[$i][0], $aCtrlPos[0] + $aMPosNew[0] - $aMousePos[0], _ $aCtrlPos[1] + $aMPosNew[1] - $aMousePos[1]) Sleep(100) Until Not _IsPressed("01") $aDesktopIcon[$i][1] = ControlGetPos($hProgMan, "", $aDesktopIcon[$i][0]) ExitLoop EndIf Next EndIf EndFunc How can I prevent the window from gaining focus - Always on bottom? The only viable solution is where the interface remains responsive but when clicking on lets say for example and image on the interface then it shouldn't appear to have minimized all of the other windows. Thanks to anyone willing to offer suggestions. I enjoy cooperating on projects with others so that is why I explicitly welcomed anyone to do so however it doesn't matter if they do or not. *Edit I added an example icon that can be moved. Based on CtrlResizeMove.au3 I know I've asked this before so I'll have to search around but how can you display an icon with its control background transparent. I'm using GUICtrlCreateIcon above. Edited April 3, 2013 by Decipher Spoiler Link to comment Share on other sites More sharing options...
Decipher Posted April 3, 2013 Author Share Posted April 3, 2013 James,This has been done before, have a search, there was a guy called JustinReno, BrettF and myself who I distinctly remember taking part in.Edit: Here they are.BrettF - seclinix - JustinReno - Alek - Dhilip89 - And I can't seem to find mine anymore, I'm sure I made one though...Those are cool and thanks for sharing but I'd like to create my own custom version that's more feature complete, pherhaps even complete replicate explorer at its base including the start menu, toolbars, program manager, and file manager then build on top of that but with major improvements. If I'm satisified I'll probably even convert it to C for practice.Anonymous Spoiler Link to comment Share on other sites More sharing options...
FireFox Posted April 3, 2013 Share Posted April 3, 2013 (edited) Anonymous please I care of my computer, don't hack it.Edit instead of reply :Lets please do remain on topicNo worries, if I post in a topic then I'm involved, consequently I will follow it for any help.perhaps you would enjoy doing a little more research on the groupNo need Edited April 3, 2013 by FireFox Link to comment Share on other sites More sharing options...
Decipher Posted April 6, 2013 Author Share Posted April 6, 2013 Bump , How can I prevent the window from gaining focus - Always on bottom? The only viable solution is where the interface remains responsive but when clicking on lets say for example and image on the interface then it shouldn't appear to have minimized all of the other windows. Anonymous Spoiler Link to comment Share on other sites More sharing options...
FireFox Posted April 7, 2013 Share Posted April 7, 2013 Try this : #Include <WinAPI.au3> #Include <Constants.au3> _WinAPI_SetWindowPos($hProgMan, $HWND_BOTTOM, 0, 0, 0, 0, BitOR($SWP_NOMOVE, $SWP_NOSIZE)) Br, FireFox. Link to comment Share on other sites More sharing options...
Decipher Posted April 7, 2013 Author Share Posted April 7, 2013 FireFox, It dosen't work for me. I tried multiple combinations of flags, etc. and could not get it working. Anonymous Spoiler Link to comment Share on other sites More sharing options...
FireFox Posted April 7, 2013 Share Posted April 7, 2013 Do you want your window to be "BOTTOM MOST" ? I don't see how to do that except making a child window on the Progman one. Br, FireFox. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 7, 2013 Moderators Share Posted April 7, 2013 FireFox,Do you want your window to be "BOTTOM MOST" ? I don't see how to do that_WinAPI_SetWindowPos with the $HWND_BOTTOM CONSTANT as a parameter would look a good starting place. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
FireFox Posted April 7, 2013 Share Posted April 7, 2013 (edited) Has it something to deal with the other thread? You lost me. Edited April 7, 2013 by FireFox Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 7, 2013 Moderators Share Posted April 7, 2013 FireFox,You asked "Do you want your window to be "BOTTOM MOST" ? I don't see how to do that." - I gave a solution. The "CONSTANT" highlight was just a bit of a joke. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
FireFox Posted April 7, 2013 Share Posted April 7, 2013 Alright Last thing, you suggested something that I or I miss something ? Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 7, 2013 Moderators Share Posted April 7, 2013 FireFox, No, I did. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Decipher Posted April 8, 2013 Author Share Posted April 8, 2013 (edited) I don't want to continue working on this unless I know I can make it work properly so I'm stuck. *Edit - I tried using your code in a loop along with other flags mentioned in the help file but its way to glitchy. Edited April 8, 2013 by Decipher Spoiler Link to comment Share on other sites More sharing options...
Decipher Posted April 17, 2013 Author Share Posted April 17, 2013 KaFu, It seems you've done a lot experimenting with preventing windows from taking the top most attribute. Perhaps you could look into this for me. If not I'm probably gonna give up on this one. Thanks Anonymous Spoiler Link to comment Share on other sites More sharing options...
KaFu Posted April 17, 2013 Share Posted April 17, 2013 Hi Decipher, afaik it's not possible to prevent some windows (e.g. the taskbar) from stealing the topmost attribute, the only workaround I've found so far is to check the topmost window in a loop and reset the order if something has changed it. Regards OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16) Link to comment Share on other sites More sharing options...
Decipher Posted April 17, 2013 Author Share Posted April 17, 2013 KaFu, Yes I read that topic but I need the opposite effect. Always on bottom. Anonymous Spoiler Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now