Bug 383505 - Apply button is disabled
Summary: Apply button is disabled
Status: RESOLVED FIXED
Alias: None
Product: plasma-nm
Classification: Plasma
Component: kcm (show other bugs)
Version: 5.10.4
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Jan Grulich
URL:
Keywords:
: 384939 388868 (view as bug list)
Depends on:
Blocks:
 
Reported: 2017-08-14 13:27 UTC by Martin Pola
Modified: 2018-01-31 06:05 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Pola 2017-08-14 13:27:01 UTC
When trying to add custom DNS servers for my wired connection, the "Apply" button is never enabled. I have tried to change most settings in the four tabs "General configuration", "Wired", "802.1x Security", "IPv4" and "IPv6", but without success. The only exception is if I check "Allow auto-negotiation", in which case the "Apply" button does become clickable.
Comment 1 David Edmundson 2017-08-14 23:02:08 UTC
Code is doing exactly what it should be.

You can't have "allow auto-negotiation" unchecked and speed set to automatic (which I assume yours is) it's an invalid configuration so you can't apply anything.

I'll remove the special-zero case of it saying automatic, so it's clearer where the bug is.
Also will be interesting to find out why your (and my) auto negotiation got disabled.
Comment 2 Martin Pola 2017-08-15 07:15:00 UTC
That makes sense, and yes, my speed was set to automatic. I installed KDE about a year ago, and as I haven't edited my wired connection manually I assume it's a left-over from whichever version Arch Linux had at that point.
Comment 3 wavemotiongun 2017-08-15 10:08:28 UTC
I just wanted to chime in for an additional confirmation.  Though my circumstances were slightly different I think it's the same issue - I was just modifying the default config after a fresh install on Antergos, to use a static IP rather than DHCP.

Not having even touched the other tabs, I was perplexed that the apply button was disabled, and that "OK" also didn't save the changes.

I see the note from David, and I get the explanation, but if there were some indication regarding why I couldn't use the "apply" button that would have helped.  I was referred here from a reddit thread where I was trying to figure out what I was doing wrong, and Martin's workaround was of course the answer.

Side note - I spend more time in Windows than I'd wish to due to my job, so that may be why I'm asking this, but is it the intent to have "OK" and "Cancel" do the same thing in this situation (which they did)?  I think I've come to expect "OK" to mean "Apply and Close".  In which case OK should also have been disabled until the autonegotiate setting was adjusted.
Comment 4 Jan Grulich 2017-09-11 11:27:45 UTC
Some reference what is going on:
https://bugs.kde.org/show_bug.cgi?id=376018
https://bugs.kde.org/show_bug.cgi?id=378554

NM switched to using a different default value for auto-negotiation so we did the same in networkmanager-qt, however it seems not to be understandable by users so in plasma-nm we still default to old/previous behaviour, which means auto-negotiation is set to true. Mixing various NM, nm-qt and plasma-nm versions where some has different behaviour then expected when all of these involved parties are updated to latest version might cause some problems.
Comment 5 David Edmundson 2017-09-11 11:50:15 UTC
Please also see a patch I made on phab that removed a duplication in the UI.

I think it makes it clearer, but it's only tested on the one version of nm.
Comment 6 Jan Grulich 2017-10-02 08:26:41 UTC
*** Bug 384939 has been marked as a duplicate of this bug. ***
Comment 7 David Edmundson 2017-10-03 11:15:47 UTC
Git commit e0642ee0d8c09d7532195b9782a5533f2f5c1506 by David Edmundson.
Committed on 03/10/2017 at 11:15.
Pushed by davidedmundson into branch 'Plasma/5.11'.

Don't duplicate UI option for automatic speed detection

Summary:
Network speed is determined automatically if "auto-negotiate" is set.
NM Spec says if that is not set a speed and duplex should be provided.

The .ui file defaulted to a speed
of 0 with had the special text of "automatic". This isn't actually
automatic, but just an invalid value which
WiredConnectionWidget::isValid (correctly) won't accept

End result is a user can't save any other settings as this widget
reports itself as invalid.

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D7315

M  +7    -1    libs/editor/settings/ui/wiredconnectionwidget.ui

https://commits.kde.org/plasma-nm/e0642ee0d8c09d7532195b9782a5533f2f5c1506
Comment 8 Jan Grulich 2018-01-31 06:05:25 UTC
*** Bug 388868 has been marked as a duplicate of this bug. ***