Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e237191

Browse files
committed
Remove unused code (found wih Vulture tool)
1 parent 6768994 commit e237191

File tree

5 files changed

+4
-12
lines changed

5 files changed

+4
-12
lines changed

CHANGELOG

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ dev
88
- add type hints
99
- add documentation (fix #10)
1010
- add tests and use Travis CI (fix #9)
11+
- remove unused code (reported by Vulture)
1112
- Linux: remove MSS library
1213
- Linux: insanely fast using only ctypes
1314
- Linux: skip unused monitors

docs/source/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
# built documents.
6060
#
6161
# The short X.Y version.
62-
version = '2.0.15'
62+
version = '2.0.17'
6363
# The full version, including alpha/beta/rc tags.
6464
release = 'latest'
6565

mss/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
from .exception import ScreenshotError
1414
from .factory import mss
1515

16-
__version__ = '2.0.15'
16+
__version__ = '2.0.17'
1717
__author__ = "Mickaël 'Tiger-222' Schoentgen"
1818
__copyright__ = '''
1919
Copyright (c) 2013-2016, Mickaël 'Tiger-222' Schoentgen

mss/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def __enter__(self):
2424

2525
return self
2626

27-
def __exit__(self, exc_type, exc_value, traceback):
27+
def __exit__(self, *_):
2828
''' For the cool call `with MSS() as mss:`. '''
2929

3030
def bgra_to_rgb(self, raw):

mss/linux.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
c_uint, c_uint32, c_ulong, c_ushort, c_void_p, cast, cdll)
1010
from ctypes.util import find_library
1111
from os import environ
12-
from sys import maxsize
1312

1413
from .base import MSSBase
1514
from .exception import ScreenshotError
@@ -253,11 +252,3 @@ def get_pixels(self, monitor):
253252
ximage = None
254253

255254
return self.image
256-
257-
258-
def arch():
259-
''' Detect OS architecture.
260-
Returns an int: 32 or 64
261-
'''
262-
263-
return 64 if maxsize > 2 ** 32 else 32

0 commit comments

Comments
 (0)