summary refs log tree commit diff stats
path: root/ranger
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-01-07 01:22:17 +0100
committerhut <hut@lavabit.com>2010-01-07 01:22:17 +0100
commitf5db66a1795d97c9f80d31b41a9607ce5cd0242b (patch)
tree59b90a2053228de596ee5ff2ef4901d625067bf3 /ranger
parent3db854eee17ff7e9c29319be04f8ae2b3e966bbf (diff)
downloadranger-f5db66a1795d97c9f80d31b41a9607ce5cd0242b.tar.gz
random cleanups and fixes
Diffstat (limited to 'ranger')
-rw-r--r--ranger/defaults/options.py2
-rw-r--r--ranger/fsobject/directory.py3
-rw-r--r--ranger/gui/widgets/browserview.py5
-rw-r--r--ranger/help/index.py6
4 files changed, 8 insertions, 8 deletions
diff --git a/ranger/defaults/options.py b/ranger/defaults/options.py
index fb1358e6..27d8b5d4 100644
--- a/ranger/defaults/options.py
+++ b/ranger/defaults/options.py
@@ -6,7 +6,7 @@ colorscheme = colorschemes.default
 max_history_size = 20
 scroll_offset = 2
 max_dirsize_for_autopreview = None
-preview_files = True
+preview_files = False
 
 sort = 'basename'
 reverse = False
diff --git a/ranger/fsobject/directory.py b/ranger/fsobject/directory.py
index 1079d126..40e8caa9 100644
--- a/ranger/fsobject/directory.py
+++ b/ranger/fsobject/directory.py
@@ -139,6 +139,8 @@ class Directory(FileSystemObject, Accumulator, SettingsAware):
 					filenames.append(join(self.path, fname))
 				yield
 
+				self.load_content_mtime = os.lstat(self.path).st_mtime
+
 				marked_paths = set(map( \
 						lambda obj: obj.path, self.marked_items))
 
@@ -185,7 +187,6 @@ class Directory(FileSystemObject, Accumulator, SettingsAware):
 			self.last_update_time = time()
 
 		finally:
-			self.load_content_mtime = os.lstat(self.path).st_mtime
 			self.loading = False
 
 	def unload(self):
diff --git a/ranger/gui/widgets/browserview.py b/ranger/gui/widgets/browserview.py
index 1635cbe0..0677a703 100644
--- a/ranger/gui/widgets/browserview.py
+++ b/ranger/gui/widgets/browserview.py
@@ -13,17 +13,16 @@ class BrowserView(Widget, DisplayableContainer):
 
 	def __init__(self, win, ratios, preview = True):
 		DisplayableContainer.__init__(self, win)
-		from functools import reduce
 		self.ratios = ratios
 		self.preview = preview
 
 		# normalize ratios:
-		ratio_sum = float(reduce(lambda x,y: x + y, ratios))
+		ratio_sum = float(sum(ratios))
 		self.ratios = tuple(map(lambda x: x / ratio_sum, ratios))
 
 		if len(self.ratios) >= 2:
 			self.stretch_ratios = self.ratios[:-2] + \
-					((self.ratios[-2] + self.ratios[-1] * 0.9), \
+					((self.ratios[-2] + self.ratios[-1] * 0.9),
 					(self.ratios[-1] * 0.1))
 		
 		offset = 1 - len(ratios)
diff --git a/ranger/help/index.py b/ranger/help/index.py
index 0f5d8727..3821bd4b 100644
--- a/ranger/help/index.py
+++ b/ranger/help/index.py
@@ -8,9 +8,9 @@
 
 	|0?|	This index
 	|1?|	Basic movement and browsing
-	|2?|	(Running Files)
-	|3?|	(The console)
-	|4?|	(File operations)
+		Running Files
+		The console
+		File operations
 
 ==============================================================================
 
/a> 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504