Show "Expired story" in the reply bar.
This commit is contained in:
		
							parent
							
								
									1b581a1597
								
							
						
					
					
						commit
						859636ff9c
					
				
					 2 changed files with 9 additions and 2 deletions
				
			
		|  | @ -1980,6 +1980,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL | ||||||
| "lng_in_dlg_sticker_emoji" = "{emoji} Sticker"; | "lng_in_dlg_sticker_emoji" = "{emoji} Sticker"; | ||||||
| "lng_in_dlg_poll" = "Poll"; | "lng_in_dlg_poll" = "Poll"; | ||||||
| "lng_in_dlg_story" = "Story"; | "lng_in_dlg_story" = "Story"; | ||||||
|  | "lng_in_dlg_story_expired" = "Expired story"; | ||||||
| "lng_in_dlg_media_count#one" = "{count} media"; | "lng_in_dlg_media_count#one" = "{count} media"; | ||||||
| "lng_in_dlg_media_count#other" = "{count} media"; | "lng_in_dlg_media_count#other" = "{count} media"; | ||||||
| "lng_in_dlg_photo_count#one" = "{count} photo"; | "lng_in_dlg_photo_count#one" = "{count} photo"; | ||||||
|  |  | ||||||
|  | @ -2016,7 +2016,11 @@ TextWithEntities MediaStory::notificationText() const { | ||||||
| 	const auto stories = &parent()->history()->owner().stories(); | 	const auto stories = &parent()->history()->owner().stories(); | ||||||
| 	const auto maybeStory = stories->lookup(_storyId); | 	const auto maybeStory = stories->lookup(_storyId); | ||||||
| 	return WithCaptionNotificationText( | 	return WithCaptionNotificationText( | ||||||
| 		tr::lng_in_dlg_story(tr::now), | 		((_expired | ||||||
|  | 			|| (!maybeStory | ||||||
|  | 				&& maybeStory.error() == Data::NoStory::Deleted)) | ||||||
|  | 			? tr::lng_in_dlg_story_expired | ||||||
|  | 			: tr::lng_in_dlg_story)(tr::now), | ||||||
| 		(maybeStory | 		(maybeStory | ||||||
| 			? (*maybeStory)->caption() | 			? (*maybeStory)->caption() | ||||||
| 			: TextWithEntities())); | 			: TextWithEntities())); | ||||||
|  | @ -2028,7 +2032,9 @@ QString MediaStory::pinnedTextSubstring() const { | ||||||
| 
 | 
 | ||||||
| TextForMimeData MediaStory::clipboardText() const { | TextForMimeData MediaStory::clipboardText() const { | ||||||
| 	return WithCaptionClipboardText( | 	return WithCaptionClipboardText( | ||||||
| 		tr::lng_in_dlg_story(tr::now), | 		(_expired | ||||||
|  | 			? tr::lng_in_dlg_story_expired | ||||||
|  | 			: tr::lng_in_dlg_story)(tr::now), | ||||||
| 		parent()->clipboardText()); | 		parent()->clipboardText()); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 John Preston
						John Preston