org.freedesktop.NetworkManager.Settings.PropertiesChanged deprecated

Hi *,

since NetworkManager 1.22 using the signal org.freedesktop.NetworkManager.
Settings.PropertiesChanged is deprecated. One should use org.freedesktop.
DBus.Properties.PropertiesChanged instead. Since NetworkManager 1.32 this 
signal indeed is completely removed.
I couldn't find any example on how to easily replace the code using the 
deprecated signal. I use PropertiesChanged to listen for connectivity changes, 
escpecially activation/deactivation of interfaces.
Goal is to configure a few things, whenever connections were (de)activated.

I use the perl module Net::DBus for this job.
The following snippet shows how far I got up to date:

  my $busobjpath = "/org/freedesktop/DBus/Properties";
  my $busif = "org.freedesktop.DBus.Properties";
  my( $oBUSIF ) = $oBUSSVC->get_object( $busobjpath, $busif ) || die $!;
        "PropertiesChanged", sub {
          &{ \&onPropertiesChanged }( @_ )
        } || die $!;
  my( $reactor ) = Net::DBus::Reactor->main();

The code seems to work, but it does not react on any changes regarding 
Networkmanager connections, at least onPropertiesChanged is never called.
The old code was using NetworkManager's special PropertiesChanged signal and 
worked as expected.

Any idea?

Thx and bye.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]