public GuiSession GetSession()
        {
            GuiApplication application = GetApplication();

            //Direkt abspeichern, um später Referenz nicht zu verlieren
            SAPFEWSELib.GuiSession session = application.ActiveSession;

            if (session == null)
            {
                System.Diagnostics.Debug.WriteLine("Session angefordert - keine active Session da :(");
                return(new NullSession());
            }
            else
            {
                System.Diagnostics.Debug.WriteLine("Session angefordert - Active Session is da");
            }
            return(new SapGuiSession(session));
        }
 private void DelegateOnFocusChanged(SAPFEWSELib.GuiSession currentSession, GuiVComponent newFocusedControl)
 {
     FocusChanged?.Invoke(GetSession(), newFocusedControl);
 }
 private void DelegateOnStartRequest(SAPFEWSELib.GuiSession currentSession)
 {
     StartRequest?.Invoke(GetSession());
 }
Beispiel #4
0
 void SAPScriptRecording_OnSetSession(SAPFEWSELib.GuiSession session)
 {
     _session       = session;
     this.IsEnabled = true;
 }
Beispiel #5
0
 public SapGuiSession(SAPFEWSELib.GuiSession session)
 {
     this.session = session;
 }