From c9f81a24ca3a2e12f42e955abe413864f22d6c4d Mon Sep 17 00:00:00 2001 From: Rod Roark Date: Mon, 28 May 2012 16:37:51 -0700 Subject: [PATCH] Improved fix for race conditions when creating a new instance of the main window. --- interface/main/left_nav.php | 1 + interface/main/main_screen.php | 10 ++++++++++ interface/main/main_title.php | 4 ++++ interface/patient_file/summary/demographics.php | 4 ++-- 4 files changed, 17 insertions(+), 2 deletions(-) diff --git a/interface/main/left_nav.php b/interface/main/left_nav.php index 9fb526d35..9411efdb4 100644 --- a/interface/main/left_nav.php +++ b/interface/main/left_nav.php @@ -376,6 +376,7 @@ function genFindBlock() { $(document).ready(function (){ getReminderCount();// + parent.loadedFrameCount += 1; }) // end of tajemo work dated reminders counter diff --git a/interface/main/main_screen.php b/interface/main/main_screen.php index 35fd5224a..862fa5b34 100644 --- a/interface/main/main_screen.php +++ b/interface/main/main_screen.php @@ -65,6 +65,16 @@ if (!empty($GLOBALS['gbl_nav_area_width'])) $nav_area_width = $GLOBALS['gbl_nav_ diff --git a/interface/main/main_title.php b/interface/main/main_title.php index cd20bb885..7ce83d32f 100644 --- a/interface/main/main_title.php +++ b/interface/main/main_title.php @@ -116,5 +116,9 @@ $res = sqlQuery("select * from users where username='".$_SESSION{"authUser"}."'" + + diff --git a/interface/patient_file/summary/demographics.php b/interface/patient_file/summary/demographics.php index 1cefe9f95..eeeeb0c24 100644 --- a/interface/patient_file/summary/demographics.php +++ b/interface/patient_file/summary/demographics.php @@ -396,8 +396,8 @@ $(document).ready(function(){ // function setMyPatient() { - // Avoid race conditions with loading of the left_nav frame. - if (!parent.left_nav.setPatient) { + // Avoid race conditions with loading of the left_nav or Title frame. + if (!parent.allFramesLoaded()) { setTimeout("setMyPatient()", 500); return; } -- 2.11.4.GIT