Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Property Pages #140

Open
anthonydotmoe opened this issue Oct 31, 2024 · 2 comments
Open

Support for Property Pages #140

anthonydotmoe opened this issue Oct 31, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request gui Something within the gui module

Comments

@anthonydotmoe
Copy link

I'm working on writing an MMC Snap-in, and I'd like to use winsafe to handle property sheet pages. All MMC wants is for you to create your property sheet pages using the Win32 CreatePropertySheetPage function, then pass the returned HPROPSHEETPAGE to the supplied COM interface (IPropertySheetCallback). It seems like property sheet pages are simply modeless dialog boxes presented in a tabular format, so I think that adapting should be simple enough.
I briefly tried extending the library, creating a PropsheetPage struct similar to the RawModeless struct, but I still haven't traced how everything would fit together. I could continue to try implementing it, but it would help if I could get some guidance on a preferred structure for the implementation.

@rodrigocfd rodrigocfd self-assigned this Nov 1, 2024
@rodrigocfd rodrigocfd added enhancement New feature or request gui Something within the gui module labels Nov 1, 2024
@rodrigocfd
Copy link
Owner

I never used property sheets before, but as far as I could see, its implementation isn't straightforward... so far, I found this example, is it enough for your needs? Do you have a better one?

I will start implementing CreatePropertySheetPage and related stuff.

@anthonydotmoe
Copy link
Author

I just uploaded a barebones example of making a property sheet page here: propsheetpage-example.

What I was thinking winsafe could do is give me the same type of abstraction as a normal window or dialog from resource id, except instead of running the dialog directly, it could give me an HPROPSHEETPAGE. The CreatePropertySheetPage function really just needs the DlgProc address and the resource ID for the dialog. It could be exactly like in this example, except we could expose a .get_hpropsheetpage from the wnd member.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request gui Something within the gui module
Projects
None yet
Development

No branches or pull requests

2 participants