def abort(max_x, max_y): text = _( 'Press Ctrl+c to exit or any key to continue. After exiting the installer please reboot the system or press Ctrl+Alt+F2 to get an shell prompt.' ) message = objects.warning(text, max_y, max_x) message.draw() c = stdscr.getch() return 0
def next_screen_profile(view_warning): installer.obj[installer.current].put_result(installer.result) installer.obj[installer.current].profile_prerun() if installer.obj[installer.current].profile_complete(): result = installer.obj[installer.current].run_profiled() if result: installer.result.update(result) installer.profile[installer.obj[ installer.current].modheader()] = result i = 1 if installer.current + i >= len(installer.modules): debug('>= len(self.modules)') installer.write_profile(1) return 2 while installer.check_depends(installer.current + i): i = i + 1 if installer.current + i >= len(installer.modules): debug('>= len(self.modules)') installer.write_profile(1) return 2 installer.current = installer.current + i return 0 else: installer.write_profile(1) if hasattr(installer.obj[installer.current], 'message'): debug('%s' % installer.obj[installer.current].message) if hasattr(installer.obj[installer.current], 'message') and (hasattr(installer.obj[installer.current], 'view_warning') or view_warning): view_warning = 1 missing = installer.obj[installer.current].message if missing: message = objects.warning(missing, installer.max_y, installer.max_x) message.draw() stdscr.getch() installer.obj[installer.current].layout_reset() debug('incomplete: %d' % installer.current) for i in installer.obj[installer.current].modvars(): if not installer.obj[installer.current].all_results.has_key(i): installer.obj[installer.current].all_results[i] = '' if not view_warning: installer.left_menu() installer.obj[installer.current].startIt = 1 installer.draw_all() return 1
def next_screen_profile(view_warning): installer.obj[installer.current].put_result(installer.result) installer.obj[installer.current].profile_prerun() if installer.obj[installer.current].profile_complete(): result=installer.obj[installer.current].run_profiled() if result: installer.result.update(result) installer.profile[installer.obj[installer.current].modheader()]=result i=1 if installer.current+i >= len(installer.modules): debug('>= len(self.modules)') installer.write_profile(1) return 2 while installer.check_depends(installer.current+i): i=i+1 if installer.current+i >= len(installer.modules): debug('>= len(self.modules)') installer.write_profile(1) return 2 installer.current=installer.current+i return 0 else: installer.write_profile(1) if hasattr(installer.obj[installer.current], 'message'): debug('%s' % installer.obj[installer.current].message) if hasattr(installer.obj[installer.current], 'message') and (hasattr(installer.obj[installer.current], 'view_warning') or view_warning): view_warning=1 missing=installer.obj[installer.current].message if missing: message=objects.warning(missing,installer.max_y,installer.max_x) message.draw() stdscr.getch() installer.obj[installer.current].layout_reset() debug('incomplete: %d' % installer.current) for i in installer.obj[installer.current].modvars(): if not installer.obj[installer.current].all_results.has_key(i): installer.obj[installer.current].all_results[i]='' if not view_warning: installer.left_menu() installer.obj[installer.current].startIt=1 installer.draw_all() return 1
def next_screen(): if hasattr(installer.obj[installer.current], 'postrun'): installer.obj[installer.current].postrun() missing=installer.obj[installer.current].incomplete() if missing: if type(missing) == type(1): return 0 message=objects.warning(missing,installer.max_y,installer.max_x) message.draw() c = None while c != 27: c = stdscr.getch() installer.draw_all() else: installer.result_update() i=1 while installer.check_depends(installer.current+i): i=i+1 if installer.chg_current(i): return 1 return 0
def next_screen(): if hasattr(installer.obj[installer.current], 'postrun'): installer.obj[installer.current].postrun() missing = installer.obj[installer.current].incomplete() if missing: if type(missing) == type(1): return 0 message = objects.warning(missing, installer.max_y, installer.max_x) message.draw() c = None while c != 27: c = stdscr.getch() installer.draw_all() else: installer.result_update() i = 1 while installer.check_depends(installer.current + i): i = i + 1 if installer.chg_current(i): return 1 return 0
def abort(max_x,max_y): text=_('Press Ctrl+c to exit or any key to continue. After exiting the installer please reboot the system or press Ctrl+Alt+F2 to get an shell prompt.') message=objects.warning(text, max_y, max_x) message.draw() c = stdscr.getch() return 0