From eff60c9a9214aa46c7792e34dad0f174920b0c48 Mon Sep 17 00:00:00 2001
From: Terry Truong <terry06890@gmail.com>
Date: Thu, 10 Mar 2022 15:46:18 +1100
Subject: Add sweep-to-narrower-document-side. Do some minor reorganisation.

---
 src/components/TileTree.vue | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/components/TileTree.vue')

diff --git a/src/components/TileTree.vue b/src/components/TileTree.vue
index dd91fcb..65201c5 100644
--- a/src/components/TileTree.vue
+++ b/src/components/TileTree.vue
@@ -71,11 +71,11 @@ export default {
 		},
 		tryLayout(){
 			let layout = LAYOUT_SYS.genLayout(this.tree, 0, 0, this.width, this.height, true);
-			shiftEmpty(layout);
 			if (layout == null){
 				console.log('Unable to layout tree');
 				return false;
 			} else {
+				shiftEmpty(layout);
 				this.applyLayout(layout, this.tree);
 				return true;
 			}
-- 
cgit v1.2.3

