summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2009-12-22 16:19:20 +0100
committerhut <hut@lavabit.com>2009-12-22 16:19:20 +0100
commit85f45f481311ff3fb241c89c824ccc80583cd99a (patch)
treea7b87ebf70f8d4376448673b56b9a570fb8163b9
parent4fb1670e4d87aecf2eee8a1ba4903f9d8cdae914 (diff)
downloadranger-85f45f481311ff3fb241c89c824ccc80583cd99a.tar.gz
some clean ups
-rw-r--r--ranger/fsobject/directory.py6
-rw-r--r--ranger/gui/defaultui.py2
-rw-r--r--ranger/gui/ui.py4
-rw-r--r--ranger/gui/widgets/filelist.py2
-rw-r--r--ranger/gui/widgets/titlebar.py4
5 files changed, 11 insertions, 7 deletions
diff --git a/ranger/fsobject/directory.py b/ranger/fsobject/directory.py
index 2478616d..5ad07ef1 100644
--- a/ranger/fsobject/directory.py
+++ b/ranger/fsobject/directory.py
@@ -16,7 +16,6 @@ class NoDirectoryGiven(Exception):
 	pass
 
 class Directory(SuperClass, SettingsAware):
-	scheduled = False
 	enterable = False
 	loading = False
 
@@ -97,6 +96,11 @@ class Directory(SuperClass, SettingsAware):
 		it takes rather long.
 		"""
 
+		self.load_once()
+
+		if schedule is None:
+			schedule = self.size > 30
+
 		if not self.loading:
 			if schedule and self.fm:
 				self.loading = True
diff --git a/ranger/gui/defaultui.py b/ranger/gui/defaultui.py
index ccfe960d..a031f93c 100644
--- a/ranger/gui/defaultui.py
+++ b/ranger/gui/defaultui.py
@@ -33,7 +33,7 @@ class DefaultUI(UI):
 		y, x = self.env.termsize
 
 		notify_hei = self.notify.requested_height
-		log(notify_hei)
+#		log(notify_hei)
 
 		self.filelist_container.resize(1, 0, y - 2 - notify_hei, x)
 		self.notify.resize(y - 1 - notify_hei, 0, notify_hei, x)
diff --git a/ranger/gui/ui.py b/ranger/gui/ui.py
index e55b9ba9..da633698 100644
--- a/ranger/gui/ui.py
+++ b/ranger/gui/ui.py
@@ -91,8 +91,8 @@ class UI(DisplayableContainer):
 		except:
 			return
 
-		from ranger import log
-		log('{0:0>28b} ({0})'.format(event.bstate))
+#		from ranger import log
+#		log('{0:0>28b} ({0})'.format(event.bstate))
 
 		if DisplayableContainer.click(self, event):
 			return
diff --git a/ranger/gui/widgets/filelist.py b/ranger/gui/widgets/filelist.py
index b4c756f1..952a6d45 100644
--- a/ranger/gui/widgets/filelist.py
+++ b/ranger/gui/widgets/filelist.py
@@ -74,7 +74,7 @@ class FileList(Widget):
 
 	def finalize(self):
 		if self.postpone_drawing:
-			self.target.load_content_if_outdated(schedule=True)
+			self.target.load_content_if_outdated(schedule=None)
 			self.draw_directory()
 			self.postpone_drawing = False
 
diff --git a/ranger/gui/widgets/titlebar.py b/ranger/gui/widgets/titlebar.py
index 36ed1168..7bb21886 100644
--- a/ranger/gui/widgets/titlebar.py
+++ b/ranger/gui/widgets/titlebar.py
@@ -120,9 +120,9 @@ class Bar(object):
 		rightsize = self.right.sumsize()
 		nonfixed_items = self.left.nonfixed_items()
 
-		log(leftsize, fixedsize, nonfixed_items)
+#		log(leftsize, fixedsize, nonfixed_items)
 		itemsize = int(float(wid - rightsize - fixedsize) / nonfixed_items) + 1
-		log(itemsize)
+#		log(itemsize)
 
 		for item in self.left:
 			if not item.fixed:
tter hut <hut@lavabit.com> 2010-03-31 05:29:35 +0200 rebuilt pydoc' href='/akspecs/ranger/commit/doc/pydoc/ranger.shared.settings.html?h=v1.8.0&id=a614f0485f872bfca3a84fb3400a0c6177988413'>a614f048 ^
34a60763 ^
f07bb12f ^
62cd83ba ^


f07bb12f ^








62cd83ba ^
f07bb12f ^







a614f048 ^

f07bb12f ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126