def pressed(self): """Displaying the lastest news on the screen""" media = self.comboBox.currentText() # News from the CNN if media == "CNN": information = news.Infogetter() answer = information.cnn() self.process(answer) # News from the New York Times if media == "New York Times": information = news.Infogetter() answer = information.nytimes() self.process(answer) # News from the Vox if media == "Vox": information = news.Infogetter() answer = information.vox() self.process(answer) # News from the Fox News if media == "Fox News": information = news.Infogetter() answer = information.foxnews() self.process(answer)
def find_cnn(): articles = news.Infogetter().cnn() return articles
def find_fox(): articles = news.Infogetter().foxnews() return articles
def find_vox(): articles = news.Infogetter().vox() return articles
def find_ny(): articles = news.Infogetter().nytimes() return articles