* Desktop Animation (part 1): Ugly naked ohmygod architecture
* fix butthurt, fix locked scene
* Change SD icons, fixes
* Fix level update animation
* Fixes, correct butthurt
* Clean up code
* furi_assert(0) -> furi_crash("msg")
* Gui: rename none layer to desktop, update docs.
Co-authored-by: あく <alleteam@gmail.com>
		
	
			
		
			
				
	
	
		
			42 lines
		
	
	
		
			820 B
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			42 lines
		
	
	
		
			820 B
		
	
	
	
		
			C
		
	
	
	
	
	
#pragma once
 | 
						|
 | 
						|
#include "furi/pubsub.h"
 | 
						|
#include <furi.h>
 | 
						|
#include <furi-hal.h>
 | 
						|
 | 
						|
#include "dolphin.h"
 | 
						|
#include "helpers/dolphin_state.h"
 | 
						|
 | 
						|
typedef enum {
 | 
						|
    DolphinEventTypeDeed,
 | 
						|
    DolphinEventTypeStats,
 | 
						|
    DolphinEventTypeFlush,
 | 
						|
} DolphinEventType;
 | 
						|
 | 
						|
typedef struct {
 | 
						|
    DolphinEventType type;
 | 
						|
    osEventFlagsId_t flag;
 | 
						|
    union {
 | 
						|
        DolphinDeed deed;
 | 
						|
        DolphinStats* stats;
 | 
						|
    };
 | 
						|
} DolphinEvent;
 | 
						|
 | 
						|
struct Dolphin {
 | 
						|
    // State
 | 
						|
    DolphinState* state;
 | 
						|
    // Queue
 | 
						|
    osMessageQueueId_t event_queue;
 | 
						|
    FuriPubSub* pubsub;
 | 
						|
};
 | 
						|
 | 
						|
Dolphin* dolphin_alloc();
 | 
						|
 | 
						|
void dolphin_free(Dolphin* dolphin);
 | 
						|
 | 
						|
void dolphin_event_send_async(Dolphin* dolphin, DolphinEvent* event);
 | 
						|
 | 
						|
void dolphin_event_send_wait(Dolphin* dolphin, DolphinEvent* event);
 | 
						|
 | 
						|
void dolphin_event_release(Dolphin* dolphin, DolphinEvent* event);
 |