• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10.1/tcl-105/tk/tk/generic/ttk/

Lines Matching refs:pb

82 static int AnimationEnabled(Progressbar *pb)
86 Tcl_GetDoubleFromObj(NULL, pb->progress.maximumObj, &maximum);
87 Tcl_GetDoubleFromObj(NULL, pb->progress.valueObj, &value);
89 return pb->progress.period > 0
92 || pb->progress.mode == TTK_PROGRESSBAR_INDETERMINATE);
102 Progressbar *pb = clientData;
104 pb->progress.timer = 0;
106 if (AnimationEnabled(pb)) {
108 Tcl_GetIntFromObj(NULL, pb->progress.phaseObj, &phase);
114 if (pb->progress.maxPhase)
115 phase %= pb->progress.maxPhase;
116 Tcl_DecrRefCount(pb->progress.phaseObj);
117 pb->progress.phaseObj = Tcl_NewIntObj(phase);
118 Tcl_IncrRefCount(pb->progress.phaseObj);
123 pb->progress.timer = Tcl_CreateTimerHandler(
124 pb->progress.period, AnimateProgressProc, clientData);
126 TtkRedisplayWidget(&pb->core);
134 static void CheckAnimation(Progressbar *pb)
136 if (AnimationEnabled(pb)) {
137 if (pb->progress.timer == 0) {
138 pb->progress.timer = Tcl_CreateTimerHandler(
139 pb->progress.period, AnimateProgressProc, (ClientData)pb);
142 if (pb->progress.timer != 0) {
143 Tcl_DeleteTimerHandler(pb->progress.timer);
144 pb->progress.timer = 0;
155 Progressbar *pb = recordPtr;
159 if (WidgetDestroyed(&pb->core)) {
165 TtkWidgetChangeState(&pb->core, TTK_STATE_DISABLED, 0);
168 TtkWidgetChangeState(&pb->core, 0, TTK_STATE_DISABLED);
173 TtkWidgetChangeState(&pb->core, TTK_STATE_INVALID, 0);
176 TtkWidgetChangeState(&pb->core, 0, TTK_STATE_INVALID);
177 Tcl_DecrRefCount(pb->progress.valueObj);
178 pb->progress.valueObj = newValue;
180 CheckAnimation(pb);
181 TtkRedisplayWidget(&pb->core);
190 Progressbar *pb = recordPtr;
191 pb->progress.variableTrace = 0;
192 pb->progress.timer = 0;
197 Progressbar *pb = recordPtr;
198 if (pb->progress.variableTrace)
199 Ttk_UntraceVariable(pb->progress.variableTrace);
200 if (pb->progress.timer)
201 Tcl_DeleteTimerHandler(pb->progress.timer);
207 * @@@ TODO: deal with [$pb configure -value ... -variable ...]
211 Progressbar *pb = recordPtr;
212 Tcl_Obj *varName = pb->progress.variableObj;
225 if (pb->progress.variableTrace) {
226 Ttk_UntraceVariable(pb->progress.variableTrace);
228 pb->progress.variableTrace = vt;
239 Progressbar *pb = recordPtr;
242 if (pb->progress.variableTrace) {
243 status = Ttk_FireTrace(pb->progress.variableTrace);
244 if (WidgetDestroyed(&pb->core)) {
249 Ttk_UntraceVariable(pb->progress.variableTrace);
250 Tcl_DecrRefCount(pb->progress.variableObj);
251 pb->progress.variableTrace = 0;
252 pb->progress.variableObj = NULL;
257 CheckAnimation(pb);
268 Progressbar *pb = recordPtr;
275 Tk_GetPixelsFromObj(NULL, pb->core.tkwin, pb->progress.lengthObj, &length);
276 Ttk_GetOrientFromObj(NULL, pb->progress.orientObj, &orient);
293 Progressbar *pb,
309 Ttk_PlaceElement(pb->core.layout, pbar, parcel);
313 Progressbar *pb,
331 Ttk_PlaceElement(pb->core.layout, pbar, pbarBox);
336 Progressbar *pb = recordPtr;
337 WidgetCore *corePtr = &pb->core;
347 Tcl_GetDoubleFromObj(NULL, pb->progress.valueObj, &value);
348 Tcl_GetDoubleFromObj(NULL, pb->progress.maximumObj, &maximum);
349 Ttk_GetOrientFromObj(NULL, pb->progress.orientObj, &orient);
355 if (pb->progress.mode == TTK_PROGRESSBAR_DETERMINATE) {
357 pb, pbar, parcel, fraction, orient);
360 pb, pbar, parcel, fraction, orient);
368 Progressbar *pb = recordPtr;
370 interp, theme, recordPtr, pb->progress.orientObj);
375 pb->progress.period = 0;
376 pb->progress.maxPhase = 0;
381 Tcl_GetIntFromObj(NULL, periodObj, &pb->progress.period);
383 Tcl_GetIntFromObj(NULL, maxPhaseObj, &pb->progress.maxPhase);
398 Progressbar *pb = recordPtr;
411 (void)Tcl_GetDoubleFromObj(NULL, pb->progress.valueObj, &value);
416 if (pb->progress.mode == TTK_PROGRESSBAR_DETERMINATE) {
418 (void)Tcl_GetDoubleFromObj(NULL, pb->progress.maximumObj, &maximum);
424 TtkRedisplayWidget(&pb->core);
428 if (pb->progress.variableTrace) {
430 interp, pb->progress.variableObj, 0, newValueObj,
438 Tcl_DecrRefCount(pb->progress.valueObj);
439 pb->progress.valueObj = newValueObj;
440 CheckAnimation(pb);