It is working, actually. And it's ingenious too: So, you must have done something wrong earlier.
It is currently April 28th, 2024, 12:21 pm
Custom Context Menu
-
- Rainmeter Sage
- Posts: 7179
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
You do not have the required permissions to view the files attached to this post.
-
- Rainmeter Sage
- Posts: 5407
- Joined: April 12th, 2012, 9:40 pm
- Location: Cedar Point, Ohio, USA
Re: Custom Context Menu
You need to use a different mouse action because you have LeftMouseUpAction= in other code sections that react to the first mouse click action.
Try using MiddleMouseUpAction= instead of DoubleMouseClickAction= in the bang...
MiddleMouseUpAction=[!ActivateConfig "#CurrentConfig#"]
Note: Since there may be a 'space' in the #CurrentConfig# name, it is a good practice to enclose the parameter in quotation marks.
:: My DA Gallery :: Rainmeter DA Gallery :: Rainmeter Workshops :: Rainmeter Documentation :: BBCode Guide ::
-
- Posts: 34
- Joined: December 20th, 2023, 9:18 am
Re: Custom Context Menu
Sorry for the intrusion, but can I know how/why is the skin "unloading"?eclectic-tech wrote: ↑January 12th, 2024, 1:10 am LeftMouseDoubleClickAction=[!ActivateConfig #CURRENTCONFIG#] (note there is no INI file specified).
Add this to the [Rainmeter] section of each skin variant.
With that code, when you double-left-click the skin, the currently loaded variant will be unloaded, and the next variant will be loaded. This works since only 1 variant in the same folder can be active at any time.
I get that this is a trick, and a pretty good one too, and a magician never reveals the trick , but I need to know!
-
- Rainmeter Sage
- Posts: 7179
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
My apologies for answering a question asked to eclectic-tech, but since I'm able to answer...
In this case, it's just the way skin variants are functioning:
1) only one variant may be loaded at one time, so the old one is unloaded when the new one is loaded
https://docs.rainmeter.net/manual/getting-started/using-rainmeter/#Variants
2) when the variant file is not specified, the next variant from the skin folder is loaded instead:
https://docs.rainmeter.net/manual/bangs/#ActivateConfig
Therefore, the particularities of 1) and 2) make the "magic" of iterating between variants happen.
As for the how, skins are just windows created by Rainmeter on the screen, so it can control them:
https://github.com/rainmeter/rainmeter/blob/55b75a812f531aaf7510c66aef732a785a3e1302/Library/Rainmeter.cpp#L1072
-
- Posts: 34
- Joined: December 20th, 2023, 9:18 am
Re: Custom Context Menu
Well, y'all make it sound easy... Thanks for telling (even if it would have been obvious).
PS:
PS:
-
- Rainmeter Sage
- Posts: 7179
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
Nah, you're doing just fine - keep it up in the same vein. This is just as much about providing solutions as it is about trying to understand what someone else meant. Anyone can miss some detail once in a while.
-
- Posts: 5
- Joined: January 11th, 2024, 2:22 pm
Re: Custom Context Menu
I tried the skin you created and it works. My problem the problem was that I had the LeftMouseClick set to open a program, so just with the first click it opens the program and it doesn't switch the variant.But eclectic-tech suggested using the MiddleMouseClick and I had it to deactivate the config, but I really wasn't even using that action, so I replace it and it's working now!! I really want to thank you and everyone here for the support. You guys are Awesome!! Basically what I'm doing is customizing BigSur to my personal preferences and needs. I'll share the results laterYincognito wrote: ↑January 12th, 2024, 1:40 pm It is working, actually. And it's ingenious too:
Test_1.0.0.rmskin
So, you must have done something wrong earlier.
-
- Rainmeter Sage
- Posts: 7179
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Custom Context Menu
Sure thing, we're all glad that you're finally able to do what you wanted - albeit in a slightly different form than originally thought. Enjoy!BaconCR wrote: ↑January 13th, 2024, 12:56 pm I tried the skin you created and it works. My problem the problem was that I had the LeftMouseClick set to open a program, so just with the first click it opens the program and it doesn't switch the variant.But eclectic-tech suggested using the MiddleMouseClick and I had it to deactivate the config, but I really wasn't even using that action, so I replace it and it's working now!! I really want to thank you and everyone here for the support. You guys are Awesome!! Basically what I'm doing is customizing BigSur to my personal preferences and needs. I'll share the results later
P.S. By the way, if you have space for it in the skins, you could add some meter of your preference and add the said action there. Then, you'd probably be able to use whatever mouse button or behavior to iterate through variants...
-
- Posts: 5
- Joined: January 11th, 2024, 2:22 pm
Re: Custom Context Menu
Yup! But I think it's even better, cause with that MiddleMouse I don't even need to go to the menu, it's even faster!Yincognito wrote: ↑January 13th, 2024, 2:31 pm Sure thing, we're all glad that you're finally able to do what you wanted - albeit in a slightly different form than originally thought. Enjoy!
P.S. By the way, if you have space for it in the skin, you could add some meter of your preference and add the said action there. Then, you'd probably be able to use whatever mouse button or behavior to iterate through variants...