[PC-BSD Commits] r130 - in pcbsd/trunk: NetworkManager system-overlay/usr/local/share/applications/kde

svn at pcbsd.org svn at pcbsd.org
Mon Mar 12 13:59:29 PST 2007


Author: kris
Date: 2007-03-12 22:59:29 +0100 (Mon, 12 Mar 2007)
New Revision: 130

Modified:
   pcbsd/trunk/NetworkManager/NetworkManager_en.ts
   pcbsd/trunk/NetworkManager/kcm.cpp
   pcbsd/trunk/NetworkManager/networkman.ui
   pcbsd/trunk/NetworkManager/networkman.ui.h
   pcbsd/trunk/system-overlay/usr/local/share/applications/kde/pcbsdnetwork.desktop
Log:
Updates to network manager, which allow it to run in non-root mode with limited functionality

Modified: pcbsd/trunk/NetworkManager/NetworkManager_en.ts
===================================================================
--- pcbsd/trunk/NetworkManager/NetworkManager_en.ts	2007-03-12 16:58:16 UTC (rev 129)
+++ pcbsd/trunk/NetworkManager/NetworkManager_en.ts	2007-03-12 21:59:29 UTC (rev 130)
@@ -10,11 +10,11 @@
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Device Status</source>
+        <source>Local Network Adapters</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Alt+C</source>
+        <source>Display system tray icon</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
@@ -22,105 +22,153 @@
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>IP Address:</source>
+        <source>DNS 1:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>MAC Address:</source>
+        <source>DNS 2:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
+        <source>System Hostname:</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Device Status</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
         <source>Link Status:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
+        <source>IP Address:</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>MAC Address:</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
         <source>&amp;Configure</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Local Network Adapters</source>
+        <source>Alt+C</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Warning</source>
+        <source>System-wide configuration settings</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>DNS #1 is out of range! (</source>
+        <source>Remote gateway:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>) Fields must be between 0-255.</source>
+        <source>IPv6 gateway:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>DNS #2 is out of range! (</source>
+        <source>Enable IPv6 on this system</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Gateway is out of range! (</source>
+        <source>DSL / PPPoE </source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Display system tray icon</source>
+        <source>Enable PPPoE on this system</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>System Hostname:</source>
+        <source>PPPoE configuration</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>System-wide configuration settings</source>
+        <source>Username:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>DNS 1:</source>
+        <source>Password:</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>DNS 2:</source>
+        <source>Internet Connection Sharing</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Remote gateway:</source>
+        <source>Alwa&amp;ys on connection</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>DSL / PPPoE </source>
+        <source>Alt+Y</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>PPPoE configuration</source>
+        <source>PPPoE Device</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Password:</source>
+        <source>Service name (optional):</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Username:</source>
+        <source>Firewall</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>PPPoE Device</source>
+        <source>IP: </source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Alwa&amp;ys on connection</source>
+        <source>Netmask: </source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Alt+Y</source>
+        <source>Warning</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Internet Connection Sharing</source>
+        <source>DNS #1 is out of range! (</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <source>Enable PPPoE on this system</source>
+        <source>) Fields must be between 0-255.</source>
         <translation type="unfinished"></translation>
     </message>
+    <message>
+        <source>DNS #2 is out of range! (</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Gateway is out of range! (</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Configure </source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Restart the Network</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Detecting Devices...</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Enable device</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Disable device</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Device Information</source>
+        <translation type="unfinished"></translation>
+    </message>
 </context>
 <context>
     <name>NotRoot</name>

Modified: pcbsd/trunk/NetworkManager/kcm.cpp
===================================================================
--- pcbsd/trunk/NetworkManager/kcm.cpp	2007-03-12 16:58:16 UTC (rev 129)
+++ pcbsd/trunk/NetworkManager/kcm.cpp	2007-03-12 21:59:29 UTC (rev 130)
@@ -13,24 +13,24 @@
 PCBSDKCModule::PCBSDKCModule(QWidget  *parent, const char  *name, const QStringList &  list)
    :    KCModule(parent, name)
 {
-  setButtons(KCModule::Apply);
+ // setButtons(KCModule::Apply);
 
   QGridLayout *layout = new QGridLayout(this);
   layout->setAutoAdd(true);
 
-  if ( checkRoot() )
-  {
+
   netproc = new NetworkMan(parent);
   netproc->Init();
+    if ( ! checkRoot() )
+   {
+       netproc->setNotRoot();	
+    }
   netproc->reparent(this, QPoint());
 
   connect(netproc, SIGNAL(changed(bool) ), this, SLOT(configChanged() ) );
 
-  } else  {
 
-      NotRoot *nroot = new NotRoot(parent);
-      nroot->reparent(this, QPoint());
-  }
+        
    
 }
 
@@ -52,7 +52,7 @@
 
 
 void    PCBSDKCModule::defaults() {
-   load();
+   //load();
 }
 
 
@@ -90,7 +90,7 @@
 }
 
 int    PCBSDNETWORK::buttons() {
-   return KCModule::Apply; 
+ return KCModule::Apply; 
 }
 
 QString  PCBSDNETWORK::kcmoduleName() {

Modified: pcbsd/trunk/NetworkManager/networkman.ui
===================================================================
--- pcbsd/trunk/NetworkManager/networkman.ui	2007-03-12 16:58:16 UTC (rev 129)
+++ pcbsd/trunk/NetworkManager/networkman.ui	2007-03-12 21:59:29 UTC (rev 130)
@@ -750,13 +750,29 @@
                 <attribute name="title">
                     <string>Firewall</string>
                 </attribute>
+                <grid>
+                    <property name="name">
+                        <cstring>unnamed</cstring>
+                    </property>
+                    <widget class="QLabel" row="0" column="0">
+                        <property name="name">
+                            <cstring>textLabel1_4</cstring>
+                        </property>
+                        <property name="text">
+                            <string>Will be implemented soon!</string>
+                        </property>
+                        <property name="alignment">
+                            <set>AlignCenter</set>
+                        </property>
+                    </widget>
+                </grid>
             </widget>
         </widget>
     </grid>
 </widget>
 <images>
     <image name="image0">
-        <data format="PNG" length="4825">89504e470d0a1a0a0000000d4948445200000040000000400806000000aa6971de000012a049444154789ced5b7f545c7795ff90bea40f05cfa34bdc4113cbac260dd9a902520d982ab0718d10bb1c30a60dc6b460d404a36643d5ee4cd6e6cce41c730676cdeeccba58662d3aa3bb14d873c80c555c884b97490f75463709430ee9197a922c93437366588af024af7ef68fef7b304c490a68927ad67bce9ccb9d1fefbdcfbd9fefbdf7fb03e0ffb9a4ddee1bc8f9f66c19b61daa66db2e43dea642bd5f961cd9aa66832cc9503515321cd754d85e962539a46aeacf5538fe0317d2a66ff7b3dd5651f2b953b158fdb9a5bc51f764071927798e4bcb9450fe7ef19de2ddae59259fff2a5bacdbef368e158b6cb1962a16fbafaa0f7b499233333ac8b9a5f5cc4dde1f1e8d93cd64ee76fb1925df5a74b771bda9982ccc902dd667a3ed24c33a1803bc1e61c653c0c66fa2a7166b7b336fe46e631372edf2ddc6b9a428166e3115d95f661b199f10a80d3da383181f8feb7ae696b6f1bbf194eb0c0e4559f6185f922d4737dc6dbc8b44b170bba9c8fe1a4972428fdcf84d221b5da69eb8893d4a96b531265bac5bee366e0002bc926f7d6d7124978ee0f865a143e7c66fa9a397e38b7e9f7a9dd0b9711657bd059ca0e43357b!
 65863bc4cf2b21e21431b0c302217116a58d71c126a70e826b611f9f1146d5cbf9f346de325f97df6ecbb83be94926cb1fea2faa09ead4946a3295a8fb861f70d0854fe7e430f2f69f705853dcf24e33a97175fffd0b10e2a16ebe9bb825fb6589feedb417674a54466342582034275f40c937364470f757d0b3b39e27a351936aeab6b8349a6223b957c3e7ea7c1e72af9f6d9434ff905569d01c3e774addbfefe283945b6b68756a40da6bc91398221c939a3ee4952b6585f55f2edca1d738062e1b365bb5bc9217230981229638c0f909c205d6d83e438e96aa3ae9761930bb9e3b2c120f19ebf97a2b7d099e5f284e82f25158bf55babc573cf4abe6c2ab29ba6b5de67debfa9513a3fd18ffd9f35237836868d0f65a2ffec183e64c942301cc3c6f39968bad80f4dfb2882a3417c4ddb88a66810da5cc9823d9af2b96ee7dc9740d6bbd331762581ac8de918bb9440c987d3118ec6f0b1e24c047f15c3c6e24c045f8aa16662338edfe8c4a5cb5fb6a8ebb47fc4d40bda6a1db12c512cf646259f2cd8e9228748bf3e665d6d836484b4378b08d99bfb16ec886e4753ecd4cf23fa5c203907445398a5cf25fa0c06b408f699b6d9a958f8e86a30ad6836a858f85f2a6c1f9125194a868cb1271ad16f1e4370c40c68fdb0c9e5e8dc18414de956d8bedb0f875a8e460400544!
 2c9e8876d5ab7b54a400aa00995f39f9b4d4134d49520f6ea2c72d6a7636c2!
 c01b3390
b914b096cdd9485f0f9180a1fcc41f0a5184a1eca81efdf23a8bdb215b6e97e042f94e3ec795b877ae1c4eed5386179e0f3a928162b957c52b1d8a9e493793b9ce4943e3649bada4264986cf509dbe919242f93879ef27366803cf4949733dd64dd61a76e77e8da2fba45a3634c6180d147ccf70903223f584ff49161b2ee889f4a3e13abc1b56c06c816eb2e59924fab9a0a5972c098cf173c9883fe2df5b049fd707cbd1c8e7f0a62ec9512c81901a8d395003a01d4204b76233119838a3cc8722d54cd0759aa85aa7542966a50921f46fdde42c462b3c8c94962c048025bf3b2e623dfffc218ca1f36c3fdbd3082170a61de10c4d8d512749db1011a1e542f9eb8b01a47bca928f9fc9a11f96426988ac88a035e46bbc88e6e91035c6d21bd7489285a8f3b19ef22ab0f8aef25ebf16ea1670692229ed257848cd9a55e75bcedc364943c7a8c1cef2273b73ba9e493b2c55eb3525ccbaf02d9daa392f4f43655b3419264a85a2f24e9694ccfd990989c4670fc125e7ea510d7a7c368f85c21c2bf1459dbfd4337be99f1351cbb1ac0b5891a74463c48fbed7e74463c485fb71f23d301c8520d7ef0a20f7baebf1f63d9096499d311b994c0fa4de908ff3286c2824c516d8a33c5d8fff5563445c2785acec1c98920ce8f5ec1e44c0f643c3da44e1c3fbb52272c4b140b9f4dcd!
 01a94c28d8e5123d8111a936af88aa3e862b0e78196a218b77b7b2cc43561ff0926172ef613d171c13b962efe10e0efbc8ba273bc40ff5b1dfd12df284cb23d8623f35c878cfa2e759713fb07c06bc53ab922439df88fc524c989ed620bd4b4249d546044e073076b50689b5616cfe700e625766f1c5cf16a2f9a701bc7a7d0f26434d50e7be04779f1b6bd7ee47db8b1ebc3eb707cd3f75434bdb8f9e8b1efc66ae16f29a08b696ad47e7e9086a4ad7c31388e08bda7a345d0ce2fc6809befc8c0d58789e9fabd7cefce74a9db02c110cd03d9d6fbf29137899ec68ef1355c12d221832d60293e6fd3303646ea99379a542f7ed128c28d8b5c080e2aa56c67bf57e6386f4b65374989e1019497e0eebaa19b066b95f5461bb0ec926b2bf0ca89a0d860d499eb72bbfe541cdee72f87ee443835c83feb331143e0884cf27003310b92474e3f39d50d54624a61d505515b6740fa0d542963c989caec1933ff1212bab1e95cf7850b90df0fd2482da1d80fbf9301a5008c7cf82006c9065c7c2fde1985ca903962d8a855f363c9d5bea7c43e40d3bd422a2c408d9dad6b7287b1b4ce8e8268bab4447d9b753e8683b59b1cfcbe136b2ec31a12bf67919ef21bd5d141326dfb09833b4880a61dae6e460557215b0fed54a71ad2407bc4d92e4c755ad171befb3e1dae4e21c60e484ab!
 6943d8f36809dccf79f0c5753508c4c7b0f9e12c91cd3f9089c848021f0ba5!
 c3fdb21b
58d380de356e98ef6fc0c0b54e28efd88333d14ebcaeed41f7a8076bd7ec47783a806feedb0ccfe908eab5ad7047c268d072d03010803afd38a48f05f1cad53db83669038063dac40bf1953a615962b23043b1586f28f964de4e274ddb6e9203f43e9d245b3d7a0797326bac3ee0e56095a81a652d64dd910ec67b17ebf12ec18468975ef72792b27ff3204d4564f513dee45c105b0dae95ce057ea6c2b6c394ad205d0262d71bb168874772a0bca0099dffd288582c869c8c1c047e3186ca3233facfc6505e9c83daaff83032560bc00da001801be68d0d50e44e40aa99ef0c65a9136ea9060df0c1bda5163ef4a316e570aba2f3733f67c3de8f3ba06a9de8796104aaa67ad50b27f6adc609cb16d962fdbc922f5662ca3c4b5783be9d0bd97ef8dcf0a2b982f5641f431eb2b8ca257240958b835564d963ad6490b43777887980312b34d6058c7d04639f2142729c3c74cccbdcedfafd2dac5c0da6953120dfaea89a7a45961c19e65c37a03560e415dba2b901a02271c4017c4efc666c6c0c66b3199dcff5e3ec4839001f66a76b01d90373763d727202a8dd5d89b14b63306f3203b300d201dc00b07641cfcece223d3dfd0dcfe4fb5100ee1f575e3deb2f3103676fef7a807002bfa358acf4ef1091cb2b4de908b79115fb9c5c24460453f70b522535d2979398c40566cde!
 f1ce9121a0add20f9e9d5e059f1eeb09c6fcd9635f9122428059b6c50e1462c368b6b9393902507940c0772726ca8deee43e3576ae77f97783581acf559f37a5ef40827620964e56421703a80ca2b9568bcda84d8f5464caa0e4003a0a908bccf019fa513b57b6b10bb1243cec69cf9cb04cf06b592a2924fa5ad4bfbc96a1cb122512cd62f19fd40c82398905b4a2a4576f6ed24cbf6b592a3a4fd6407394076748905d4c1017dcd4faf0a1ded1d22ab9f68e54c2fb9f7b08be35d64c513ad7a3fd0ca9047f409c6fd86dbc47a02a79218a1cbe0c0e0ab9ce38af60a567d3e40b6589f972579a779431694cc0640f2407dad1eaa2ab27a7151188d5221ca4fdba0aa0ec87223b2d2654002000764b909aad608481e00f580e606a406a8aaa80eb39a5e25343726671b003441c96c840afd3ed336449e7060ec6191638c1c11381d68ddf5c8ae03abc5b56c518a98ad58ac974c452252d17651dfc7bbc9bd87457db69f22c7bbc98ac7ec1cae22cbaaac1cf6083bda4656ef7332ea23ab9f30b48b511f59b12f49b793d5075a39ec13cc2a6e99af3e2f1d3d627d7c514e10eb07b3fe6effb259f03b9d10512cdc02c971465164d356731614b91e907cc831d58a35c08c7234bc22d60027a73d5027eba1aa36c8b2becb2dd90034cd5f4f961aa1ea4c90650f14b91eaae4c3e4f55!
 aa89a07b36a3d462e39a06ab8a8aa9365eac5e66bad2dade7ebbf506f31ae1!
 1783e80c
a1d955f4a5b97d6f2bb605bb6e46ee796dcedce2b05bbc4ca4ebc57cceb0503f4d5e053a2765b9bfbc8205977a495f16e72ef01b1525477d0c5788f789ffde4d1635e7240d4f9788fce80363277bb9db9db38226fb19b8cfb33ccefa456878ef68e1f2ff7f97f2f6784f2b6330772d3734a46e34772727c3065d7223d23005346252005d12895c08d201aa412b81146835408b72666756e35880694a049eb07500e55eb870de5b06901a86a2512d77db876bd1663b12640833f764d7d6cf2e2b1f9f343ce13ce6f37fe4de3370c3bf07c009589ca5fa4d5a63df4fbc066489afeba07c03a006f03a0007827800d00de2bcbca8305a5d6ef9579a8551ff48aceee94a8e5aeb61039b1b05a6caceb7bdb454fd0ea0be93b49a25770b6887d86434ff9196d278bab5cbff697f20480fb019800dc07201380cccb7c71be63d4fb0b6f9b77ec76033701780f80cd00de0fe043001e06f071536ec117ca763b87aa0f7a49b70e2e4efa7b4533937a8e607e2f51ffdcb00f1df3b3fa00b5e25df63ec594f72880320025008af47b6e3974f0d067fd3dfe45a5d0dfe327dbf83baf0b1ac0d7e8e0ef81684c65006fc742f4df03e07d002c003ea83be11300aa72b7947db5629f3d30d3cb29eb4911596f97ded1f52f6682bf578c5f67cb203944d61df6c6875be8376d28f82a804f037804c0!
 2701fc857e8f0f171715eff07abcff930cdee818bd3e6fdb4a80be991392ff36ec64a748fa6b2d044bdeaebfd201ac8324cbc5dbaa1fc8d994f7e766936d932c77bed391519369d30290a54aa85a000eb5f27feb273d1393d7c6a223e78317472e9cb90c80fabd34fd7503c01c80b9024b4146c3918653f575f5f71b9da4d11906cf045172a5e4d1b4fd695d005e07f0dbd53a20595297ce0c76a4be0c27c849af7400f7ea7faf4d72de3dfa6f921dfb6672235a157d20bc37fcd735bb6b16fae95701ac07f012807cbc92f5aeace2c9eb9353100efb2d6ee1046999375eea02c67b8673d2f41baa007e8d05b046ee90b1e0887549da70c62d9d60da60ca881d8ced0f9605ffb2a67861ff239110738bf04b61143e5408dbdfda8e4d5e9f7c7d99b8ee881849742d041b3221b2b809402e802d1049ad084031808f02d8016027804f298af299a3478e7e9f64627e366948ca4992d696d6ef42540a05c2d906c3de52b2064b975233800720126a816983a9d47eccfe0ffe6e7f9c24678c23a7fa94391a15dd4f282cb6e15a3dadcf4354a53fd5af6d0cb1b786f847b9a1c2c7c767e6f8acb59f81e173dc0c20030b6cd808c03cee19dfe96a767d9fe4d4fc1ee14c8a36ce0be89177b95d3e007900de05c1b0b5583afa778e0d4a33950237ab2a7c7459c9910efda1fdfa86675f94!
 af718a8d00d617e4176cb61fb77f9d3ebe181a12119d999a59a4e313c659a4!
 e1e4c8ab
f6e376bb0efedd00de01c12e2329a7ca6d744090b2d2ccd2be281d656d7c313ec31b4e63de6f442cf5e0b4e8dd5ff6f7524db2dfa8e74f8ae87d4490e40447aaabaaab21864d0e44e46f063eb58cff7e45696676451b5fdb3b45d675937533645d0f6925e937c0df44e2ba5386f5f3803371a353d44f8e8e461781f777fba7789c7f27cbf20701bc17228764e0d6b4bf7de001c074929f27c98e2111dd903e76bdfa4e5028357b1b92fabeb1066844da38172868ff1b67b3f3dff2b6e49501d80a9133ee83a82cd232c0df3e0754b7d1dfd123c6aeb57f7164a3290ba086334291a5bd32aed37e3038381f71e709e70f0a8a0a3e09512eff0c22d3674294bae4866a29d046d3767bc4748e99d66ece7280749d3824263ea38b411976ab71d2c3f87c6ef1f70cdbe52319e17f1f3d7cd4ae28cac300f221e61cef069085c551bf2be08de646329d98799c240f1d394ac6abe9f51d224f911d6141813e3d81f5e92749df005a97c1f17927250ab6953d02e0210005108dd246007f0231c75887c594bf15f8db26691049e7dee8659e76b5f9c5f81db093249ded4e46c3a4ab5b0777b3ff159a58cc10ff28c9397600f8800efc3d00b275e0f7de04f81d076fdcf01e00f7e635c70f579ce4c0f0807d9224e34356924efa7baca4bb82d6636293c498e71bff2334cf8c145dfd94f7331!
 02d723644764f067eb3c9d31d039e2cc6ecef5e006f27c7af72f4904011164c0875d9c973a4b3455fb44839f76f804eca115188b26624b8a5c6f95b4ae68782eba982f564f58f79ae4e25c9f1a09da49df6e376f214d93734be2468a3497205397434ce4fe28d65ed2d093c598c4cbb16c0bde4f0e718d97b83d473c200d9daa5ef08a580f79ee30d92fe3acff027602ca0dcbc8dfd839134ce549867c2d567c8bad9a3275b1324d91799498ef8ac33c8bfaf9be203f8038bf6b2855365196c29cbe61cffd938e7e71a628ce437eaba79e7fec1e16ecbde2ee692fce1d15eee2f3bcee5ae40fd51fe287748fe0fd5b88a6b0069bd7d0000000049454e44ae426082</data>
+        <data format="PNG" length="4788">89504e470d0a1a0a0000000d4948445200000040000000400806000000aa6971de0000127b49444154789ced5b7f505cd775fe909fe4470299878bdcdd468ad9269285ba4e80e044103901aa343228290351648b28b2c14a228892a8223fdc5db5d6ec6a269a85346a769b2a6513d3eec68d0c7806ede29696558acd2ac581b4488007794023a9bb1aacd9a532595ed073befe71df83650d36e04872a639336f0e6777df7def3be7dcf3e3de0bf0ff9cd26ef503e43c47b60cfb0e55b36f97216f53a1de274bce6c55b3439664a89a0a19ce6b2aecafc8923ca06aeacf5438ff1d17d2a66ff5bbdd5252f2b853b1da023925bc59fb8d36324172888bd30dc10221926364d16ef78c92c77f96adb6ed771ac78a49b6da4a14abe3bfaa0ef9489289840e7276719e58e2f3e1b118d94ce66c779c55f26c85771ad75b92c9ca0cd96a7b3ad6497250076380d72dcc580ad8d812fcc642ee68e6cd9c6d6c428e43bed3381725c5ca2da642c72b6c25639302b5c1133a884824a6f3c49bcac67d919471fafac759fa285f92ad4736dc69bc0b48b172bba9d0f11a497252b75c6409cb8e2f934f2e218f91a5a71995adb62d771a3700015ec9b3bdb6d0928b5b307259f081a1c89bf2f1cbb105f7a78e3330146151e53b40094a1e736!
 4ab2dca499297750b19dcf000c37223820deb9cfd82f5f52f211b968fa47063fc1069dac68bf2071cd977067d0925d96afb45d5413d5a931c1f4fe1bac50db9a757a00a840c3ebca8dc1316f29c2719e35c5e387efdd1362a56db993b825fb6da9e1ad841b675a458662cc582bd82b5750deb7c79f29cc5f56c326c8cab73c3934c850e2a797cec7683cf51f21c33f54f060456dd03868774aecb81d038394bb69c1e5811373ce58d9e2394941c336abf41ca56dbab4a9e43b96d0a50ac7cba74770b3944f685532c65ccf15e923748776b1f1923ddadd4f93264723e765c363c448c17e85ee8596eef00fb4a48c56afbebd5e2b96b253f36153a4cd35af73f7c7053a3743e12c2fecf5b103e17c5c60733113a37818fe46721fc52141bcf67a2e942089af6718447c2f8bab6114d636168b3c5f3f248caf7ba6cbe278eacf7a663e24a1c591bd33171318ee28fa663702c8a4f14658af1755e3db919dfbed98e8b97bf6255d769dfc78d17b4d52a6259a4581d8d4a1e99bfd34d0e91017dceba5bfbc871d2d12c644773cfbc3caecb911439f5fb71bd17488e01e3299ea5f7123d86079c2239429ab639a858f9c86a30ada81b54ac7c5185fd63b22443c99031f1782342960984472d8016825d2e43fbc611543fbc15f6ef86e054cbd08820800a281921d8a77559ab00a4209a5!
 031f7bdc51446436d31a2afcec0bc3e1d131371582c5918b918c7d64d59183!
 c1f45c10
366845f8aa2f84133fccf8da0e6ca56d8a743085f28c3b9f3f636f5c2f1ddab51c2f2c0e75151ac362a79a4627550c9237377b8c8d9f9b9e96e1d2047c816bf905dde3e7292ac7f3240f693f54ffac86eb2f6904b97db741e107d835131a678805147ccd509bd224ed88ef7902364ede100953cc657836bd91e205b6dbb64493ea36a2a64c909a39fcf7fc08cd0963ad8a5109cdf2c83f3efc298b8540c39230875ba02403b806a64c91ec4a7a250910b59ae81aaf9214b3550b576c852358af30651b7b700d1e80ccce6240f188d636b6ed69ce5432f4ca0ec210b3c3f1c44f842012c1bc298b85a8c8eb37640c303eacbc72fac46116f494a1ebf6e583ed9134c8564f9011f635d645b679227509fd311d276cc4576915507c5ef9279a25b70f627593ca5ae1830ba4b3debf84e0f9311f2c85132d145e66c7751c92365aba37aa5b8969f05b2b54724e9a96daa668724c950b56e48d253989eb5233e358dd0e58b78e55201aec707d1f085020cfe52446dcf8f3df876c6d7d17829886b93d5f00f7991f69bfdf00f7991be6e3f7e3915842c55e3472ffab1e7fa0731911d4796251d2317e358bf291d83bf8ca2203f53649ba24c31f77fb5154d4383784a36e358248cf363573095e8828ca7fad5c963e756aa84659162e5d3a93120d513f277b9c57c352cd5ea13f3599fc3e5!
 077c1c6f258b76b7b0d44f561df09123e4de437a2c382a62c5de436d8c7490b5df681337ea73bfad936482747b8567394ef691a105efb3e27a60f91e70af562949729e61f9c53c617a5a8374af84e2ca8d089e0962e26a35e26983d8fc5133a25766f0a5cf17e078308857afefc1d47f36419dfd323cffeac1dab5fbe17dd18bd767f7e044d0032d6d3f3a2e78f1ebd91ac86b46b0b5743ddacf8ca07ae77a78db47f0256d3d9a2e84717eac184ffcc00eccbfcfcfd46b67ff63a54a5816090fd0359de758d2133849b69dee11b1c0232c3860ac0526f7fdfd644e898bb925820fec121e91bf6bde038a2a5bc8def97ac3779aa2c2f40e90e3c9ef615bb507ac59ee0f55d8af43b28be82f03aa6687214392e7e48a6f7951bdbb0cfe9ff8d1205723742e8a820780c1f371c0028c5c14bce1b976a86a23e2d34ea8aa8aafa47b01ad06b2e4c5d474359e78ce8facac3a147fdf8b8a1288b9bf0bf03c37880614c079260cc00e5976ce3f1fcea9952a60d9a458f91543d33925ae3758de90c75b458ee638d9d2dab3207a1b9ed0d64916558a8a7260a7e0b14eb27c9f8f91d364e9a38297eff39121d2d741d130f98745cf704a640ad33617872b93b380edcf578a6b2531e05d92243fa66addd8788f1dd7a616c60023265c7cbd1f7b1e2986e7192fbeb4ae1ac1d804363f9425a2!
 f9873231321ac72706d2e179c503ac6940e71a0f2cf735a0fb6a3b94f7ec41!
 d7583b5e
d7f6e0a7235eac5db31fe1a920be7d6033bccf8ea04edb0acfd0201a34331a4241a8d38f41fb441897aeeec1b5293b001cd5265f88ad5409cb229395198ad57653c9237377ba68dab6440c30aa35922d5ebd824be91aab0ef8385c29b246692b597bb88dec5dc8135dc213625d7adebf9114fd9bfb682a24ab1ef725c782e86a70adb417f83715f61da66c05e91210bdde88053b3c921365f94d68ff5123a2d128ccd966045f9c4045a905a1735194159951f3553f46276a0078003400f0c0b2b1018adc0e48d57395a12cb5c32355a3017e78b6d4c08f106a50068f2a2a3fcfb376ecfda413aad68eae1746a16aaa4fbd707cdf6a94b06c92adb627943cb11253ea5f3c1b0cec9c8ff6c343c30b7a05db891e8efbc9a24ab78801956e0e5792a58fb69083a4a3b94df403465768ac0b18fb08c63ec308c918597fd4c79cedfaf3adac580da69579409e435135f58a2c39332c391e406bc0e825fb82de0050113fec04be20ee99989880c56241fbb3219c1b2d03e0c7cc740d207b61c9ae83d91c44cdee0a4c5c9c806593059801900ee02680b5f37c666606e9e9e96f7827ff4f82f03c5371f55ca0d8029cbbb5eb014209fc9e62b5b16f87b05c6e494a45b88d2cdfe7e202322c98ba5f904aa996be9ce4499cf7acb99d239d06fa076e92fcec6af0ac787758ceb365cb9a7c111!
 294fc4d76a8f0201a9dc1b5a929c892134a861366b31d55dbfd68fc6acddc7df157e3c85a9f35c7e748b7703c1a4796390bc13341545ca940e3d52644af37624a75021a004d45f0034ef8adeda8d95b8de89528cc1bcd73c384cf85b5e2a2e24fa7a5a5fdcb6a14b12252acb62f1bf5c0b85f78424e09a9143a38b0932cddd7425e261d27448ddfd6211650fb7af5353f3d2bb49d6e1351fdb8a8f8f61e7233d145963fdea2d7032d1cf78b3ac1785ee4b4be9e309be4113af5f5f6bd4a72457b05ab3e1f205b6dcfcb92bcd3b2210b4a66032079a1be5607551551bda870108d5201caced8a1aa4ec87223b2d2654002002764b909aad608485e007580e601a406a8aac80e339a9e25340fa6661a003441c96c840afd39d3768c3ceec4c44322c61831227826d8b2eb33bb0eac16d7b2492964b662b55d34150a4bc53a457e4f74937b0f89fcec384926bac9f2471d8c5492a5953646fc428e9d26abf6b918eb20ab1e37b89bb10eb27c5f12ef24ab0eb430d2213caba8752efbbc74e4b0edb1053141ac1fcc043a03cbf682b7754244b1720b24e75945914d5b2d5950e43a40f2c36caa116b80196568b824d600a7a6bd50a7eaa0aa76c8b2becb2dd90134cd8d274b8d50754f90652f14b90eaae4c7d4f51aa89a17336a1d462f3aa16a785955a74ad5979bafb59c6a395ff7c!
 53aab3146f0f9202a1eaef8725a5adaa9b7836dd994b39d5b72b6bbaee4efd!
 257767af
5be7e9c749cd457834f8af96a6bee2107c9dac32d6437b9f7805829aa3de82643fae761f2c8519fbe3e207a81aa032226e46c7730671b47e52d0e93f17c8ef07ba9d9a1ed74db33cb7dffdfca19a1dced34436e7a56c968fc98d9ec8729bb06e9194198322a00298c46a9181e84d12015c38341344805f068a2abf3a86134a0184d5a084019542d043bca60d78250d50ac4affb71ed7a0d26a24d808640f49afae8d4cb47e7ce0fb98ebbbed3f8978ddf32e4e0f34154c42b7e915693f6e06f039b4169fa7517807500de054001702f800d00de2fcbca03f925b61f96faa9551df489caee24c9497d8df0c6fc6ab1b1aeef3b2d727e8b7f40df49123582eb94d867a87f32c058275954e9fe555f098f03b80f8009c03d003201c89ce4cfe72a46bdbef0b5fa266e35701380f701d80ce083003e02e021009f34e5e47fb174b7abbfeaa08ff4e8e01264a05b1433a9e708e6f612f5ef0db9fe68805507a815ed72f428a6dc47009402280650a83f734bfdc1facf07ba020b5261a02b40b6f26daf0b1ac0d7e8e0ef82284c6500efc6bcf5df07e00300ac003eac2be153002a73b6947ead7c9f23c85edeb09d10d6f175e8155d68a12704ba49ceea961f226b0ff9629156064c1bf2bf06e0b3003e03e061007faa3fe3a34585453b7c5edfff2483372a469fdfd7ba12a06fa584e4bf!
 0d395929927ead85f09277eb573a80759064b9685bd5fde64db97f6231d937c972fbbdce8cea4cbb16842c5540d58270aa15ff5b37e59d9cba36313e7a3efcf2e885b39701507f96a65f3701cc0298cdb7e667341c6e3859575b779f51491a9561f86c18c5578a1f49db9fd601e07500bf59ad02922975e9ccf08ed4cb50829c74a503b85bff7b6d92f2eed2ef4956ec5bd1cd5865ecfed0ded05f54efae9eafa75f05b01ec04b001ec4a5acf5594553d7a76e4028ec3778132548cb7cf06203189f19ca49d31fa802f815e6c11ab143c6bc22d6257143196faa04d3065346f460747fb834fc67d545f3fb1ff1b8e82d065f1a44c18305b0ff95fde8d4f5a9d79789ebb6901144d74278432644143701c801b00522a815022802f071003b00ec04f06945513e77e4f0911f938ccf759306a59c246939d5f203884ca14028dbf0b07714adc1e2a9d402e07e88809a6fda602a711c75fc6da0331023c98471e4546f99c7c745f5333028b6e15abc2dcf4364a53fd4c736a6d83b83fa2e7343b99f8f917cda16623032c6cd003230ef0d1b015812fec44e77b3fbc7246fcced112652b8715e40b7bcdbe3f603c805f047101eb6168b5bfff67983d24c25dfc3ca723fdd3672b44d7fe980bee1d933ced738cb4600ebf3f3f2373b8e39be493f7f3ed02f2c9ab89158c06393c659a4e1!
 64cbab8e630e870efebd00de03e15d46504ea55ba88041ca4a334b06227496!
 b6f2e724
6fba8cbedfb058eac16951bbbf12e8a69a24bf91cf9d14d1eb8830c91b1cadaaacaa8298366608cb2f053e358dff7649696676792b5fdb3b4bd67692b5246bbb481bc980017e098ae94a19d6cf03266246a5a89f1c1d1b5f003ed019b8c163fcae2ccb1f06f07e881892813777fb5b071e004c27f80449b6e97b0203fadcf5e93b4103a9d1dba0d4cf8d3540c3d2c6b940e1f6bf7635bb7e9abb25b714c0568898710f4466919601fed629a0aa9581b62e31776da185961d4f590035943130b2b85622badbf785fbe62cee3aeefac7fcc2fc8721d2e51f4344fa4c8854975c502d06da28da6e0d99c69869ebe40cfb49f7f17ad1f88c2d0465c82dc6490fe3fbd985bf3364b79fe438fffbc8a1230e45511e029007d173bc174016165afd8e80378a1bc9743cf11849d61f3e4226aae8f3d79327c9b641e1023d7a00ebd14f92be01b44e7d913925c5f3b7957e06c08300f2210aa58d00fe00a2c75887852eff66e06f19a541049dbb63933ce36e0d885d9c5e0749d275dac5d808e9d6cf0cf52df5bf42930b3d44e76d003ea4037f1f806c1df8dd4b00bfede08d07de05e0eedce6d8a1f213ec1dee754c9164acdf46d2c540978df494d376546c92187dbef13f42739e91c2ab9ef47d0ea244ce8688eec9c0976a9e6e1bf06432babfbb01bc9b4c5ce558bd4031283c61a0c3418!
 e91ae53faa245cab97f0374528c1887486b46805b6c9ebfa3686e2ab89fcc5f4f563dc3a15a952423610749071dc71ce449b2a73fb22868a3487287d97f24c187f1c6b4f68e049e4c46a45d0be06e32f2058eecbd49ea31a19f6ce9d0778452c0fb86789364a0d63bfc29180b284b97b1bf339446965b12835567c9da9923275ae224d9339248b6f88c2bccbfa99de5fdf81db3f6b289b3a5193c559a4df2ef8d5323ee7e46497eabb693b7ef1f1cee34eded600ec97f3ad2cdfda5c7b8dc15a8dfd3efe936d1ff01ab219539b82ae1d30000000049454e44ae426082</data>
     </image>
 </images>
 <connections>
@@ -895,6 +911,7 @@
     <function access="private">savePPPOEConfig()</function>
     <function access="private">updatePPPconf()</function>
     <function access="private">disablePPPOEConfig()</function>
+    <function>setNotRoot()</function>
 </functions>
 <layoutdefaults spacing="6" margin="11"/>
 </UI>

Modified: pcbsd/trunk/NetworkManager/networkman.ui.h
===================================================================
--- pcbsd/trunk/NetworkManager/networkman.ui.h	2007-03-12 16:58:16 UTC (rev 129)
+++ pcbsd/trunk/NetworkManager/networkman.ui.h	2007-03-12 21:59:29 UTC (rev 130)
@@ -215,7 +215,8 @@
     
     if ( sel != -1 ) {
     
-	pushConfigure->setEnabled(TRUE);
+    pushConfigure->setEnabled(TRUE);
+
 	
     // Check to see if the network tray icon is enabled or not
      QString filename = "/home/" + username + "/.kde/Autostart/tray-" + Devs[sel] + ".desktop";
@@ -295,6 +296,7 @@
 
 void NetworkMan::PropertiesSlot()
 {
+    
     workingDev = listNetDev->currentItem();
     
     if ( workingDev != -1) {
@@ -302,6 +304,13 @@
     if ( DevsType[workingDev] == "Wireless" )
     {
 	    ConfigDevice = new QProcess( this );
+	    // If we are running as root
+	    if ( getuid() != 0 )
+	    {
+		ConfigDevice->addArgument( "kdesu");
+		ConfigDevice->addArgument( "-d");
+		ConfigDevice->addArgument( "--noignorebutton");
+	    }
 	    ConfigDevice->addArgument( "/PCBSD/networkmanager/bin/wificonfig");
 	    ConfigDevice->addArgument( Devs[workingDev] );
     
@@ -312,6 +321,13 @@
     } else {
    
     ConfigDevice = new QProcess( this );
+     // If we are not running as root
+     if ( getuid() != 0 )
+    {
+	ConfigDevice->addArgument( "kdesu");
+	ConfigDevice->addArgument( "-d");
+	ConfigDevice->addArgument( "--noignorebutton");
+    }
     ConfigDevice->addArgument( "/PCBSD/networkmanager/bin/ethernetconfig");
     ConfigDevice->addArgument( Devs[workingDev] );
     
@@ -661,6 +677,7 @@
 		
 		if ( firstUpdate == 0) {
 		DevsMAC[i] = getMacForIdent(Devs[i]);
+		listNetDev->setCurrentItem(0);
 	             }
 
 		if ( DevsType[i] == "Wireless")
@@ -754,6 +771,12 @@
        return;	
     }
     
+        // If we are running as root
+    if ( getuid() != 0 )
+    {
+	return;
+    }
+    
     QString Type;
     
     // Start the tray applet
@@ -1064,16 +1087,21 @@
 
 void NetworkMan::slotListRightClick( QListBoxItem *item, const QPoint &pos )
 {
+   
     int currentItem = listNetDev->currentItem();
     if ( currentItem != -1 ) {
 	  popup = new KPopupMenu();
 	  popup->insertItem( tr("Configure ") + Devs[currentItem], this, SLOT(PropertiesSlot()));
 	  popup->insertItem( tr("Device Information"), this, SLOT(slotShowInfoConfig()));
+	  // If we are running as root
+	  if ( getuid() == 0 )
+	  {
 	  popup->insertSeparator();
 	  popup->insertItem( tr("Enable device"), this, SLOT(slotEnableDevice()));
 	  popup->insertItem( tr("Disable device"), this, SLOT(slotDisableDevice()));
                 popup->insertSeparator();
                 popup->insertItem( tr("Restart the Network"), this, SLOT(restartNetwork()));
+	  }
 	  popup->exec( QCursor::pos() );
     }
 
@@ -1110,6 +1138,13 @@
     if ( DevsType[workingDev] == "Wireless" )
     {
 	    ConfigDevice = new QProcess( this );
+	     // If we not are running as root
+	    if ( getuid() != 0 )
+	    {
+		ConfigDevice->addArgument( "kdesu");
+		ConfigDevice->addArgument( "-d");
+		ConfigDevice->addArgument( "--noignorebutton");
+	    }
 	    ConfigDevice->addArgument( "/PCBSD/networkmanager/bin/wificonfig");
 	    ConfigDevice->addArgument( "info");
 	    ConfigDevice->addArgument( Devs[workingDev] );
@@ -1121,6 +1156,13 @@
     } else {
    
     ConfigDevice = new QProcess( this );
+     // If we not are running as root
+     if ( getuid() != 0 )
+    {
+	ConfigDevice->addArgument( "kdesu");
+	ConfigDevice->addArgument( "-d");
+	ConfigDevice->addArgument( "--noignorebutton");
+    }
     ConfigDevice->addArgument( "/PCBSD/networkmanager/bin/ethernetconfig");
     ConfigDevice->addArgument( "info");
     ConfigDevice->addArgument( Devs[workingDev] );
@@ -1134,3 +1176,31 @@
     
   }
 }
+
+
+void NetworkMan::setNotRoot()
+{
+    // Disable functionality since we are not running as root
+    checkSysTray->setEnabled(FALSE);
+    pushConfigure->setEnabled(FALSE);
+    lineDNS1->setEnabled(FALSE);
+    lineDNS2->setEnabled(FALSE);
+    checkIPv6Enable->setEnabled(FALSE);
+    lineHostname->setEnabled(FALSE);
+    lineGateway->setEnabled(FALSE);
+    lineIPv6Gateway->setEnabled(FALSE);
+    //tabNetMan->setEnabled(FALSE);
+    
+    checkPPPOE->setEnabled(FALSE);
+    linePPPUsername->setEnabled(FALSE);
+    linePPPPassword->setEnabled(FALSE);
+    linePPPService->setEnabled(FALSE);
+    comboPPPOEDev->setEnabled(FALSE);
+    checkPPPAlwaysOn->setEnabled(FALSE);
+    checkPPPNat->setEnabled(FALSE);
+    
+    
+    
+    
+    
+}

Modified: pcbsd/trunk/system-overlay/usr/local/share/applications/kde/pcbsdnetwork.desktop
===================================================================
--- pcbsd/trunk/system-overlay/usr/local/share/applications/kde/pcbsdnetwork.desktop	2007-03-12 16:58:16 UTC (rev 129)
+++ pcbsd/trunk/system-overlay/usr/local/share/applications/kde/pcbsdnetwork.desktop	2007-03-12 21:59:29 UTC (rev 130)
@@ -3,12 +3,13 @@
 Exec=kcmshell pcbsdnetwork
 Icon=network_local
 Type=Application
-Name=PC-BSD Network Manager
+Name=Network Configuration
 
 X-KDE-ModuleType=Library
-X-KDE-SubstituteUID=true
 X-KDE-Library=pcbsdnetwork
+X-KDE-ParentApp=kcontrol
+X-KDE-HasReadOnlyMode=false
 X-KDE-RootOnly=true
-X-KDE-ParentApp=kcontrol
 
+
 Categories=Qt;KDE;X-KDE-settings-system;



More information about the Commits mailing list