Advertisement
Guest User

Untitled

a guest
Dec 9th, 2019
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.16 KB | None | 0 0
  1. template<class T>
  2. class TreapNode{
  3. public:
  4.  
  5. // STEP-BY-STEP
  6.  
  7. static void loopLatency();
  8. static void changeLoopState();
  9. void changeStepByStepMode();
  10. void setDisableStepMode();
  11.  
  12. private:
  13. static bool stepLoopSwitcher;
  14. static bool stepButStepEnable;
  15.  
  16. };
  17. template<class T>
  18. void TreapNode<T>::changeLoopState(){
  19. stepLoopSwitcher = false;
  20. }
  21.  
  22. template<class T>
  23. void TreapNode<T>::changeStepByStepMode(){
  24. stepButStepEnable = true;
  25. }
  26.  
  27. template<class T>
  28. void TreapNode<T>::setDisableStepMode(){
  29. stepButStepEnable = false;
  30. }
  31.  
  32. template<class T>
  33. void TreapNode<T>::loopLatency(){
  34. qDebug() << "Loop latency for step-by-step started" << endl;
  35. for( ; ; ) {
  36. QApplication::processEvents();
  37. if(stepLoopSwitcher == false) break;
  38. }
  39. stepLoopSwitcher = true;
  40. }
  41.  
  42. void MainWindow::onStepTreapDrawingButtonClicked() {
  43. //TreapNode<int>::changeLoopState(); // если здесь откоментрировать то падает
  44. }
  45. //:-1: ошибка: symbol(s) not found for architecture x86_64
  46. //:-1: ошибка: linker command failed with exit code 1 (use -v to see invocation)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement