Advertisement
Guest User

DynamicModule

a guest
Jun 22nd, 2013
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. DynamicModule[{color = RGBColor[0, 0, 0], CellChangeTime, cell},
  2. CellPrint[cell = Cell[BoxData[""], "Input", Background -> Dynamic[color],
  3. Evaluatable -> True, CellEvaluationFunction -> Function[
  4. CellChangeTime = CellChangeTimes /. Cases[
  5. Cell, Rule[a_, b_] -> Rule[a, b]
  6. ];
  7. color = RGBColor[1, 1, 1];
  8. ]]
  9. ];
  10. Refresh[
  11. If[Not[boxData == recent],(*
  12. the following doesn't work for comparison *)
  13. color = Lighter[Gray, 0.7];
  14. , Null], UpdateInterval -> 1];
  15. ];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement