D23125: fix bridge master:slave mapping by-name

Harald Sitter noreply at phabricator.kde.org
Tue Aug 13 14:45:14 BST 2019


sitter created this revision.
Herald added a project: Plasma.
Herald added a subscriber: plasma-devel.
Herald added a reviewer: jgrulich.
sitter requested review of this revision.

REVISION SUMMARY
  a slave may be mapped to a master by either the uuid of the master OR
  the connection name of the master.
  
  determine our current connection name and if it is the one referenced by
  the slave we consider ourselves master of that slave.
  since we do not have access to the connection name inside the bridgewidget
  I'm opting to pop it out of connection list on-demand. it may be
  more efficient to get it passed in by the parent widget (which I think
  knows the name). I am not sure if there may be pitfalls with considering
  the name static though.
  
  also partially unpack the if condition so it's a bit easier on the eyes
  with the newly added complexity

TEST PLAN
    nmcli c add type bridge ifname br0 autoconnect yes con-name br0 stp off
    nmcli c add type bridge-slave autoconnect yes con-name enp4s0 ifname enp4s0 master br0
  
  kcm correctly shows enp4s0 as slave of br0

REPOSITORY
  R116 Plasma Network Management Applet

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D23125

AFFECTED FILES
  libs/editor/settings/bridgewidget.cpp

To: sitter, jgrulich
Cc: plasma-devel, LeGast00n, The-Feren-OS-Dev, jraleigh, fbampaloukas, GB_2, ragreen, Pitel, ZrenBot, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20190813/09e088d6/attachment.html>


More information about the Plasma-devel mailing list