문제

In my application i have two buttons and one function and when i click certain button function takes certain parameter and executing with its value, when i click another button it function takes another parameter and executing, how to do that? All of this things is done dynamically. Function and buttons are in different classes.

connect(AddButtonSimpleWindow,SIGNAL(clicked(MyWindowSettings)),area,SLOT(AddSubWindow(MyWindowSettings)));
connect(AddButtonParameterWindow,SIGNAL(clicked(MyWindowSettings)),area,SLOT(AddSubWindow(MyWindowSettings)));

Where i should emit signal? And how to override it?

도움이 되었습니까?

해결책

Where i should emit signal? And how to override it?

This part of your code looks correct if the sender and receiver objects are pointers. Please make sure they are.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top