mirror of
https://github.com/markqvist/Sideband.git
synced 2025-08-03 12:06:07 -04:00
Included local plyer
This commit is contained in:
parent
25f0d52260
commit
f23855fb68
166 changed files with 15862 additions and 0 deletions
23
sbapp/plyer/platforms/linux/devicename.py
Normal file
23
sbapp/plyer/platforms/linux/devicename.py
Normal file
|
@ -0,0 +1,23 @@
|
|||
'''
|
||||
Module of Linux API for plyer.devicename.
|
||||
'''
|
||||
|
||||
import socket
|
||||
from plyer.facades import DeviceName
|
||||
|
||||
|
||||
class LinuxDeviceName(DeviceName):
|
||||
'''
|
||||
Implementation of Linux DeviceName API.
|
||||
'''
|
||||
|
||||
def _get_device_name(self):
|
||||
hostname = socket.gethostname()
|
||||
return hostname
|
||||
|
||||
|
||||
def instance():
|
||||
'''
|
||||
Instance for facade proxy.
|
||||
'''
|
||||
return LinuxDeviceName()
|
Loading…
Add table
Add a link
Reference in a new issue