diff --git a/mauplay/id3.c b/mauplay/id3.c index 20f39a9..a5509a4 100644 --- a/mauplay/id3.c +++ b/mauplay/id3.c @@ -1,9 +1,9 @@ #include "mauplay.h" unsigned char* id3_findimage(const char* path, size_t* size) { - size_t fsz; + size_t fsz; unsigned char* buffer = MDEID3GetTag(path, "APIC", &fsz); - unsigned char* d = NULL; + unsigned char* d = NULL; int i; if(buffer == NULL) return NULL; for(i = 1; i < fsz; i++) { diff --git a/mauplay/mauplay.h b/mauplay/mauplay.h index 8ad2b5d..543407b 100644 --- a/mauplay/mauplay.h +++ b/mauplay/mauplay.h @@ -37,13 +37,13 @@ typedef struct queue { } queue_t; /* main.c */ -extern MwWidget window; -extern MwWidget album, info; -extern MwWidget bskipback, bplay, bpause, bstop, bskipfwd, brepeat, bshuffle; -extern MwWidget eltime, seekbar, rmtime; -extern MwWidget tree, list; +extern MwWidget window; +extern MwWidget album, info; +extern MwWidget bskipback, bplay, bpause, bstop, bskipfwd, brepeat, bshuffle; +extern MwWidget eltime, seekbar, rmtime; +extern MwWidget tree, list; extern unsigned char* pxalbumdata; -extern MwLLPixmap pxalbum; +extern MwLLPixmap pxalbum; /* db.c */ extern numkv_t* db_musics; diff --git a/mauplay/ui.c b/mauplay/ui.c index 138b226..3886c96 100644 --- a/mauplay/ui.c +++ b/mauplay/ui.c @@ -203,21 +203,21 @@ int queue_last = -1; static void window_tick(MwWidget handle, void* user, void* client) { pthread_mutex_lock(&audio_mutex); if(queue_last != queue_seek && queue_seek != -1) { - int ind; - char* buf; - size_t sz; + int ind; + char* buf; + size_t sz; unsigned char* img; img = id3_findimage(queue[queue_seek].path, &sz); - if(img != NULL){ - int iw, ih, ic; + if(img != NULL) { + int iw, ih, ic; unsigned char* data = stbi_load_from_memory(img, sz, &iw, &ih, &ic, 4); - if(data != NULL){ + if(data != NULL) { int y, x; - for(y = 0; y < ALBUMWIDTH; y++){ - for(x = 0; x < ALBUMWIDTH; x++){ - int ix = x * iw / ALBUMWIDTH; - int iy = y * ih / ALBUMWIDTH; + for(y = 0; y < ALBUMWIDTH; y++) { + for(x = 0; x < ALBUMWIDTH; x++) { + int ix = x * iw / ALBUMWIDTH; + int iy = y * ih / ALBUMWIDTH; unsigned char* ipx = &data[(iy * iw + ix) * 4]; unsigned char* opx = &((MwLLCommonPixmap)pxalbum)->raw[(y * ALBUMWIDTH + x) * 4];