tempSL--;   issueEvent(new StartLevelEvent(StartLevelEvent.DEC_FW_SL, i-1, newSL, callerBundle, framework)); } } } framework.publishFrameworkEvent(FrameworkEvent.STARTLEVEL_CHANGED, callerBundle, null); if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) { Debug.println("StartLevelImpl: doSetStartLevel: STARTLEVEL_CHANGED event published");
tempSL--; decFWSL(i - 1); } } framework.publishFrameworkEvent( FrameworkEvent.STARTLEVEL_CHANGED, callerBundle, null); if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) { Debug.println( "StartLevelImpl: doSetStartLevel: STARTLEVEL_CHANGED event published"); }
    private void doSetStartLevel (int newSL, boolean sync, Bundle callerBundle) {                int tempSL = activeSL;                if (sync) {            if (newSL > tempSL) {                for (int i=tempSL; i < newSL; i++) {                	if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) {						Debug.println("sync - incrementing Startlevel from "+tempSL);                	}                                        tempSL++;                                        startLevelListener.incFWSL(new StartLevelEvent(StartLevelEvent.INC_FW_SL, i+1, newSL, callerBundle, framework));                }            } else {                for (int i=tempSL; i > newSL; i--) {					if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) {                        Debug.println("sync - decrementing Startlevel from "+tempSL);					}                    tempSL--;                                        startLevelListener.decFWSL(new StartLevelEvent(StartLevelEvent.DEC_FW_SL, i-1, newSL, callerBundle, framework));                }            }        } else {            if (newSL > tempSL) {                for (int i=tempSL; i < newSL; i++) {                	if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) {                        Debug.println("async - incrementing Startlevel from "+tempSL);                	}                    tempSL++;                    // do the startlevel change asynchronously                    issueEvent(new StartLevelEvent(StartLevelEvent.INC_FW_SL, i+1, newSL, callerBundle, framework));                }            } else {                for (int i=tempSL; i > newSL; i--) {					if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) {                        Debug.println("async - decrementing Startlevel from "+tempSL);					}                    tempSL--;                                                            // do the startlevel change asynchronously                    issueEvent(new StartLevelEvent(StartLevelEvent.DEC_FW_SL, i-1, newSL, callerBundle, framework));                }            }        }        framework.publishFrameworkEvent(FrameworkEvent.STARTLEVEL_CHANGED, callerBundle, null);		if (Debug.DEBUG && Debug.DEBUG_STARTLEVEL) {            Debug.println("StartLevelImpl: doSetStartLevel: STARTLEVEL_CHANGED event published");		}    }