[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: =?utf-8?q?=5Bkcmgrub2=5D_/=3A_Add_license_headers=2C_change_bad_?=
From: Alberto Mattea <alberto () mattea ! info>
Date: 2011-04-06 12:54:20
Message-ID: 20110406125420.96170A60A9 () git ! kde ! org
[Download RAW message or body]
Git commit ccacea590c3501e0a757d5085455fe78b75960c9 by Alberto Mattea.
Committed on 06/04/2011 at 14:33.
Pushed by mattea into branch 'master'.
Add license headers, change bad variable name
M +18 -3 kcmgrub2.py
M +15 -0 pbkdf2.py
http://commits.kde.org/kcmgrub2/ccacea590c3501e0a757d5085455fe78b75960c9
diff --git a/kcmgrub2.py b/kcmgrub2.py
index 05f4a48..52543a8 100755
--- a/kcmgrub2.py
+++ b/kcmgrub2.py
@@ -1,6 +1,21 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+# Grub2 Control Module
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program 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 General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from PyKDE4.kdecore import *
@@ -10,10 +25,10 @@ from PyQt4 import uic
import os, locale, re
try:
import Xlib, Xlib.display
- x=True
+ xlibAvailable=True
except:
print("No python XLib bindings found")
- x=False
+ xlibAvailable=False
import pbkdf2
@@ -728,7 +743,7 @@ class PyKcm(KCModule):
self.resDiag.show()
def getScreenResolution(self):
- if x:
+ if xlibAvailable:
display = Xlib.display.Display()
root = display.screen().root
desktop = root.get_geometry()
diff --git a/pbkdf2.py b/pbkdf2.py
index cc0f882..436db54 100644
--- a/pbkdf2.py
+++ b/pbkdf2.py
@@ -1,6 +1,21 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+# Python pbkdf2 generator
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program 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 General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
from math import ceil
from functools import partial
from hashlib import sha512
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic