Removed unneeded messages
This commit is contained in:
		
							parent
							
								
									07907177e7
								
							
						
					
					
						commit
						822da269ff
					
				
					 2 changed files with 3 additions and 8 deletions
				
			
		|  | @ -29,21 +29,16 @@ class MonitorThread:#(Thread): | ||||||
|     def run(self): |     def run(self): | ||||||
|         if self.player.player_state == "PLAYING": |         if self.player.player_state == "PLAYING": | ||||||
|             position = self.player.position() |             position = self.player.position() | ||||||
|             duration = self.player.duration() |  | ||||||
|             if position < 0: # handle invalid operation |  | ||||||
|                 position = duration |  | ||||||
| 
 |  | ||||||
|             print("\rTime Left: {0}".format(duration - position)) |  | ||||||
| 
 | 
 | ||||||
|             # handle finishing of limited playtime |             # handle finishing of limited playtime | ||||||
|             if self.player.playtime > 0: |             if self.player.playtime > 0: | ||||||
|                 if (position - self.player.startpos) - self.player.playtime <= 0: |                 if (position - self.player.startpos) > self.player.playtime: | ||||||
|                     #self._player.pause(notify=False) |                     #self._player.pause(notify=False) | ||||||
|                     print "Finished limited play" |                     print "Finished limited play" | ||||||
|                     self.player._finished() |                     self.player._finished() | ||||||
| 
 | 
 | ||||||
|         if self._running and time is not None: |         if self._running and time is not None: | ||||||
|             GObject.timeout_add(20, self.run) |             GObject.timeout_add(100, self.run) | ||||||
| 
 | 
 | ||||||
| class MonitoredPlayer(BasicPlayer): | class MonitoredPlayer(BasicPlayer): | ||||||
|     def __init__(self): |     def __init__(self): | ||||||
|  |  | ||||||
|  | @ -30,7 +30,7 @@ class TestController: | ||||||
|         GObject.timeout_add(10, self.tick) |         GObject.timeout_add(10, self.tick) | ||||||
| 
 | 
 | ||||||
|     def tick(self): |     def tick(self): | ||||||
|         self.player.QuickLoop("/opt/src/robotvideo/ogen open.mp4") |         self.player.QuickLoop("/opt/src/robotvideo/ogen open.mp4",5) | ||||||
|         #GObject.timeout_add(3000, self.reboot) |         #GObject.timeout_add(3000, self.reboot) | ||||||
|         pass |         pass | ||||||
|          |          | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue
	
	 Miqra Developer
						Miqra Developer