Example #1
0
/**
 * Toggles blackout screen and sends out a signal indicating the new state of the blackout screen
 */
void LiveScreen::blackoutWindow() {
	blackoutScreen->raise(); // Ensure that the blackout screen is always on top of the everything
	if (blackoutScreen->isHidden())
		blackoutScreen->show();
	else
		blackoutScreen->hide();
	emit isBlackout(!blackoutScreen->isHidden());
}
Example #2
0
bool rulesSystem::addBlackout(string blackoutDate)
{

  //To prevent duplicates, it checks if the date is already 
  if (!isBlackout(blackoutDate)) {
  
    m_blackout.push_back(blackoutDate);
    
    //Now sort the data for easy usage
    
    insertion_sort(m_blackout);
  
    return (m_blackout.back() == blackoutDate);

  }

  return false;
  
}