__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
# -*- Mode: Python; py-indent-offset: 4 -*- # vim: tabstop=4 shiftwidth=4 expandtab # # Copyright (C) 2025 James Henstridge <[email protected]> # # _enum.py: base classes for enumeration and flags types. # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2.1 of the License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # Lesser General Public License for more details. # # You should have received a copy of the GNU Lesser General Public # License along with this library; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 # USA import enum import warnings from . import _gi class GEnumMeta(enum.EnumMeta): def __new__(metacls, name, bases, classdict, /, **kwargs): enum_class = super().__new__(metacls, name, bases, classdict, **kwargs) # If __gtype__ is not set, this is a new enum or flags defined # from Python. Register a new GType for it. if "__gtype__" not in enum_class.__dict__: type_name = enum_class.__dict__.get("__gtype_name__") _gi.enum_register(enum_class, type_name) return enum_class @property def __enum_values__(self): from gi import PyGIDeprecationWarning warnings.warn( 'Calling "__enum_values__" on enums is deprecated.', PyGIDeprecationWarning ) return {m.value: m for m in self} class GEnum(enum.IntEnum, metaclass=GEnumMeta): __module__ = _gi.__name__ __gtype__ = None class GFlagsMeta(enum.EnumMeta): def __new__(metacls, name, bases, classdict, /, **kwargs): flags_class = super().__new__(metacls, name, bases, classdict, **kwargs) # If __gtype__ is not set, this is a new enum or flags defined # from Python. Register a new GType for it. if "__gtype__" not in flags_class.__dict__: type_name = flags_class.__dict__.get("__gtype_name__") _gi.flags_register(flags_class, type_name) return flags_class @property def __flags_values__(self): from gi import PyGIDeprecationWarning warnings.warn( 'Calling "__flags_values__" on flags is deprecated. ', PyGIDeprecationWarning, ) return {m.value: m for m in self} class GFlags(enum.IntFlag, metaclass=GFlagsMeta): __module__ = _gi.__name__ __gtype__ = None
| Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| __pycache__ | Folder | 0755 |
|
|
| overrides | Folder | 0755 |
|
|
| repository | Folder | 0755 |
|
|
| __init__.py | File | 6.33 KB | 0644 |
|
| _constants.py | File | 1.88 KB | 0644 |
|
| _enum.py | File | 2.65 KB | 0644 |
|
| _error.py | File | 1.91 KB | 0644 |
|
| _gi.cpython-312-x86_64-linux-gnu.so | File | 389.01 KB | 0755 |
|
| _gi_cairo.cpython-312-x86_64-linux-gnu.so | File | 22.6 KB | 0755 |
|
| _gtktemplate.py | File | 9.71 KB | 0644 |
|
| _option.py | File | 13.29 KB | 0644 |
|
| _ossighelper.py | File | 8.4 KB | 0644 |
|
| _propertyhelper.py | File | 13.99 KB | 0644 |
|
| _signalhelper.py | File | 9.29 KB | 0644 |
|
| _signature.py | File | 6.3 KB | 0644 |
|
| docstring.py | File | 6 KB | 0644 |
|
| events.py | File | 29.92 KB | 0644 |
|
| importer.py | File | 5.15 KB | 0644 |
|
| module.py | File | 8.39 KB | 0644 |
|
| pygtkcompat.py | File | 240 B | 0644 |
|
| types.py | File | 13.11 KB | 0644 |
|