static public SessionUploadWindow Show(Gtk.Window parent) { if (SessionUploadWindowBox == null) { SessionUploadWindowBox = new SessionUploadWindow(parent); } SessionUploadWindowBox.session_upload.Show(); return(SessionUploadWindowBox); }
private static bool pulseGTKServer() { if (!thread.IsAlive) { sessionUploadWin.UploadFinished(); LogB.Information("dying"); return(false); } if (serverSessionError) { new DialogMessage(Constants.MessageTypes.WARNING, Catalog.GetString("Error uploading session to server")); return(false); } //need to do this, if not it crashes because chronopicWin gets died by thread ending sessionUploadWin = SessionUploadWindow.Show(app1); if (countPersons == 0) { sessionUploadWin.PulseProgressbar(); } //activity on pulsebar sessionUploadWin.UpdatePulsebar(); if (needUpdateServerSession && !updatingServerSession) { //prevent that FillData is called again with same data updatingServerSession = true; //update progressBar sessionUploadWin.UpdateProgressbar( Util.DivideSafeFraction(++countPersons, progressBarPersonsNum)); //fill data sessionUploadWin.FillData(sessionUploadPersonData); //not need to update until there's more data coming from the other thread updatingServerSession = false; needUpdateServerSession = false; } Thread.Sleep(50); LogB.Debug(thread.ThreadState.ToString()); return(true); }
void on_session_upload_delete_event(object o, DeleteEventArgs args) { SessionUploadWindowBox.session_upload.Hide(); SessionUploadWindowBox = null; }
void on_button_close_clicked(object o, EventArgs args) { SessionUploadWindowBox.session_upload.Hide(); SessionUploadWindowBox = null; }
public static SessionUploadWindow Show(Gtk.Window parent) { if (SessionUploadWindowBox == null) { SessionUploadWindowBox = new SessionUploadWindow (parent); } SessionUploadWindowBox.session_upload.Show (); return SessionUploadWindowBox; }
private static bool pulseGTKServer() { if(! thread.IsAlive) { sessionUploadWin.UploadFinished(); Log.Write("dying"); return false; } if (serverSessionError) { new DialogMessage(Constants.MessageTypes.WARNING, Catalog.GetString("Error uploading session to server")); return false; } //need to do this, if not it crashes because chronopicWin gets died by thread ending sessionUploadWin = SessionUploadWindow.Show(app1); if(countPersons == 0) sessionUploadWin.PulseProgressbar(); //activity on pulsebar sessionUploadWin.UpdatePulsebar(); if(needUpdateServerSession && !updatingServerSession) { //prevent that FillData is called again with same data updatingServerSession = true; //update progressBar sessionUploadWin.UpdateProgressbar( Util.DivideSafeFraction(++countPersons, progressBarPersonsNum)); //fill data sessionUploadWin.FillData(sessionUploadPersonData); //not need to update until there's more data coming from the other thread updatingServerSession = false; needUpdateServerSession = false; } Thread.Sleep (50); Log.Write(thread.ThreadState.ToString()); return true; }