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

Re: [PATCH newui 1/5] Network spoke: initial files

> +class NetworkSpoke(NormalSpoke):
> +    builderObjects = ["networkWindow"]
> +    mainWidgetName = "networkWindow"
> +    uiFile = "spokes/network.ui"

This is an annoying little bit of duplication, but you need to add:

       title = N_("NETWORK CONFIGURATION")

or you won't get a title on the hub.  I should fix it to pull this
information from the glade file, but for now just add it to your code.

You'll also need an icon.  The one on the mockups is:

       icon = "network-transmit-receive-symbolic"

> +    @property
> +    def completed(self):
> +        # enabled?
> +        pass

Your completed method should return a boolean, probably based on whether
or not there is any networking up at all.

> +    @property
> +    def status(self):
> +        # active connections?
> +        pass

Yeah, you should return some string here.  The mockups indicate a string
like "Wired (ethX) connected" or "Wireless (ethX) connected to
'Whatever'".  Also a default like "Not connected" would be helpful.  In
that case, the completed method can just check whether status == "Not
connected".  See ui/gui/spokes/source.py.

- Chris

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