-
Notifications
You must be signed in to change notification settings - Fork 18
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
add btn_probe_tool_setter to false if ini error #67
base: master
Are you sure you want to change the base?
Conversation
No
If user have only a probe and no tool setter this stuff is done for that
… Le 14 janv. 2021 à 12:06, Kiall Mac Innes ***@***.***> a écrit :
@kiall commented on this pull request.
In psng/python/tool_measurement.py:
> @@ -83,8 +83,7 @@ def _init_tool_sensor_data(self):
or tsdiam is None
):
self.chk_use_tool_measurement.set_active(False)
- self.btn_tool_dia.set_sensitive(False)
- self.btn_probe_tool_setter.set_sensitive(False)
+ self.frm_probe_pos.set_sensitive(False)
So, these can actually be removed now - since the error_dialog() method was added, if the INI is invalid, PSNG will show the message and then quit - so there's no need to disable the form.
I'll submit a PR that cleans the whole active/sensitive stuff in here up.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
But maybe need some refinement for inhibit only with TS value missing
… Le 14 janv. 2021 à 12:19, ***@***.*** a écrit :
No
If user have only a probe and no tool setter this stuff is done for that
>> Le 14 janv. 2021 à 12:06, Kiall Mac Innes ***@***.***> a écrit :
>>
>
> @kiall commented on this pull request.
>
> In psng/python/tool_measurement.py:
>
> > @@ -83,8 +83,7 @@ def _init_tool_sensor_data(self):
> or tsdiam is None
> ):
> self.chk_use_tool_measurement.set_active(False)
> - self.btn_tool_dia.set_sensitive(False)
> - self.btn_probe_tool_setter.set_sensitive(False)
> + self.frm_probe_pos.set_sensitive(False)
> So, these can actually be removed now - since the error_dialog() method was added, if the INI is invalid, PSNG will show the message and then quit - so there's no need to disable the form.
>
> I'll submit a PR that cleans the whole active/sensitive stuff in here up.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
|
Interesting, I hadn't considered that use case as I have both 😂 That said - with the current code in this repo, 2 lines after your change we exit the program. Adding the ability to not use a tool setter seems fine to me, but it's would be something we need to add vs something that already exists :) I've cleaned up this code, but not added that feature, in #69 We can add that on top of this pretty easily I think. |
Apologies, closed by mistake and hit enter too early - I've updated my last comment to finish it :) |
Sorry i did not take attention in my fork i have removed the sys exit and display a error message in place (without differentiating...) So i also apologies i have PR this without testing the rest of your code ! |
No description provided.