亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? wm.c

?? ucgui源碼3.32
?? C
?? 第 1 頁 / 共 4 頁
字號:
void WM__Client2Screen(const WM_Obj* pWin, GUI_RECT *pRect) {
  GUI_MoveRect(pRect, pWin->Rect.x0, pWin->Rect.y0);
}

int WM__IsWindow(WM_HWIN hWin) {
  WM_HWIN iWin;
  int r = 0;
  for (iWin = WM__FirstWin; iWin; iWin = WM_H2P(iWin)->hNextLin) {
    if (iWin == hWin) {
      r = 1;
      break;
    }
  }
  return r;
}


/*******************************************************************
*
*
*/
void WM__RemoveFromLinList(WM_HWIN hWin) {
  WM_Obj* piWin;
  WM_HWIN hiWin, hNext;
  for (hiWin = WM__FirstWin; hiWin; ) {
    piWin = WM_H2P(hiWin);
    hNext = piWin->hNextLin;
    if (hNext == hWin) {
      piWin->hNextLin = WM_H2P(hWin)->hNextLin;
      break;
    }
    hiWin = hNext;
  }
}


/*******************************************************************
*
*
*/
void _AddToLinList(WM_HWIN hNew) {
  WM_Obj* pFirst;
  WM_Obj* pNew;
  if (WM__FirstWin) {
    pFirst = WM_H2P(WM__FirstWin);
    pNew   = WM_H2P(hNew);
    pNew->hNextLin = pFirst->hNextLin;
    pFirst->hNextLin = hNew;
  } else {
    WM__FirstWin = hNew;
  }
}


/*********************************************************************
   Check if the rectangle has some content (is non-zero)
   Returns 0 if the Rectangle has no content, else 1.
*/
int WM__RectIsNZ(const GUI_RECT* pr) {
  if (pr->x0 > pr->x1)
    return 0;
  if (pr->y0 > pr->y1)
    return 0;
  return 1;
}


/*
  ********************************************************************
  *                                                                  *
  *                    Sending messages                              *
  *                                                                  *
  ********************************************************************
*/


void WM_SendMessage(WM_HWIN hWin, WM_MESSAGE* pMsg) {
  WM_Obj* pWin;
  WM_LOCK();
  if (hWin) {
    pWin = WM_H2P(hWin);
  /* Do some checking to avoid program crashes due to user
     programming errors */
    #if GUI_DEBUG_LEVEL > 0
      if (!pWin->Status)
        goto Done;
    #endif
    if (pWin->cb != NULL) {
      pMsg->hWin = hWin;
      IsInCallback = 1;
      (*pWin->cb)(pMsg);
      IsInCallback = 0;
    }
  }
  #if GUI_DEBUG_LEVEL > 0
Done:
  #endif
  WM_UNLOCK();
}

/*******************************************************************
*
*
*/
void WM__SendMsgNoData(WM_HWIN hWin, U8 MsgId) {
  WM_MESSAGE Msg;
  Msg.hWin  = hWin;
  Msg.MsgId = MsgId;
  WM_SendMessage(hWin, &Msg);
}



/* Get client rectangle in windows coordinates. This means that the
  upper left corner is always at (0,0). */
void WM__GetClientRectWin(const WM_Obj* pWin, GUI_RECT* pRect) {
  pRect->x0 = pRect->y0 = 0;
  pRect->x1 = pWin->Rect.x1 - pWin->Rect.x0;
  pRect->y1 = pWin->Rect.y1 - pWin->Rect.y0;
}


static void WM__GetInvalidRectAbs(WM_Obj* pWin, GUI_RECT* pRect) {
  *pRect = pWin->InvalidRect;
  GUI_MoveRect (pRect, pWin->Rect.x0, pWin->Rect.y0);
}


/*
          *****************************************************************
          *                                                               *
          *              Invalidation functions                           *
          *                                                               *
          *****************************************************************
*/

/* Invalidate, using window coordinates */
static void WM_InvalidateBWin1(WM_HWIN hWin, const GUI_RECT*pRect) {
  GUI_RECT r;
  WM_Obj* pWin = WM_H2P(hWin);
  WM__GetClientRectWin(pWin, &r);
  if (pRect)
    GUI__IntersectRect(&r, pRect);
  if (WM__RectIsNZ(&r)) {
    if (pWin->Status & WM_SF_INVALID) {
      GUI_MergeRect(&pWin->InvalidRect, &pWin->InvalidRect, &r);
    } else {
      pWin->InvalidRect = r;
      pWin->Status |= WM_SF_INVALID;
      WM__NumInvalidWindows++;
      /* Debug code: shows invalid areas */
      #if (WM_SHOW_INVALID)
      {
        GUI_CONTEXT Context = GUI_Context;
        WM_SelectWindow(hWin);
        GUI_SetBkColor(GUI_GREEN);
        GUI_ClearRect(r.x0, r.y0, r.x1, r.y1);
        GUI_Context = Context;
      }
      #endif


    }
  }
}

/* Invalidate, using desktop coordinates (only this window,
   not the ones below !!!)
*/
static void WM_InvalidateBWin1Abs(WM_HWIN hWin, const GUI_RECT*pRect) {
  GUI_RECT r = *pRect;
  WM_LOCK();
  GUI_MoveRect(&r, -WM_H2P(hWin)->Rect.x0, -WM_H2P(hWin)->Rect.y0);
  WM_InvalidateBWin1(hWin, &r);
  WM_UNLOCK();
}



/*
  Invalidate a certain section of the display. One main reason for this is
  that a window has been moved or destroyed.
  The following windows are affected:
  * windows below the window creating the invalidation.
  * transparent windows located above
  The coordinates given are absolute coordinates (desktop coordinates)
*/
void WM__InvalidateAreaBelow(const GUI_RECT* pRect, WM_HWIN StopWin) {
  WM_HWIN   iWin, iNext;
  GUI_USE_PARA(StopWin); /* tbd: change calls of this function */
  /* Iterate over windows below StopWin */
  for (iWin = WM__FirstWin; iWin/*!=StopWin*/; iWin = iNext) {
    GUI_RECT r = *pRect;
    WM_Obj* pWin = WM_H2P(iWin);
    iNext = pWin->hNextLin;
    if (GUI__IntersectRects(&r, &r, &pWin->Rect)) {
      WM_InvalidateBWin1Abs (iWin, &r);
    }
  };
}

/*
  Invalidate any transparent window above the given area
*/
void WM__InvalidateTransAreaAbove(const GUI_RECT* pRect, WM_HWIN StopWin) {
  GUI_USE_PARA(pRect);
  GUI_USE_PARA(StopWin);
#if 0
  WM_HWIN   iWin;
  /* Iterate over windows below StopWin */
  for (iWin = StopWin; iWin!=WM_HWIN_NULL; iWin = WM_H2P(iWin)->Next) {
    WM_Obj *pWin = WM_H2P(iWin);
    if (pWin->Status & WM_SF_HASTRANS) {
      GUI_RECT r = *pRect;
      if (GUI__IntersectRects(&r, &r, &WM_H2P(iWin)->Rect)) {
        WM_InvalidateBWin1Abs (iWin, &r);
      }
    }
  }
#endif
}


/*
          *****************************************************************
          *                                                               *
          *              Invalidation functions                           *
          *                                                               *
          *****************************************************************
*/

/* Invalidate a section of the window. The optional rectangle
   contains client coordinates, which are independent of the
   position of the window on the logical desktop area.
*/


void WM_InvalidateRect(WM_HWIN hWin, const GUI_RECT*pRect) {
  GUI_RECT r;
  WM_Obj* pWin;
  WM_LOCK();
  pWin = WM_H2P(hWin);
  WM__GetClientRectWin(pWin, &r);
  if (pRect) {
    GUI__IntersectRect(&r, pRect);
  }
  WM_InvalidateBWin1(hWin, &r);
/* Convert into absolute coordinates ... */
  GUI_MoveRect (&r, pWin->Rect.x0, pWin->Rect.y0);
/* Make sure windows below are invalidated if this one is transparent */
  if (pWin->Status & WM_SF_HASTRANS) {
    ResetNextDrawWin();
    WM__InvalidateAreaBelow(&r, hWin);
  }
/* Invalidate the transparent ones above */
  WM__InvalidateTransAreaAbove(&r,hWin);
  WM_UNLOCK();
}

void WM_InvalidateWindow(WM_HWIN hWin) {
  WM_InvalidateRect(hWin, NULL);
}

/* Invalidate, using desktop coordinates */
void WM_InvalidateBWinAbs(WM_HWIN hWin, const GUI_RECT*pRect) {
  GUI_RECT r = *pRect;
  WM_LOCK();
  GUI_MoveRect(&r, -WM_H2P(hWin)->Rect.x0, -WM_H2P(hWin)->Rect.y0);
  WM_InvalidateRect(hWin, &r);
  WM_UNLOCK();
}


/*
  Invalidate a certain section of the display. One main reason for this is
  that the top window has been moved or destroyed.
  The coordinates given are absolute coordinates (desktop coordinates)
*/
void WM_InvalidateArea(GUI_RECT* pRect) {
  WM_HWIN   iWin;
  WM_LOCK();
  /* Iterate over all windows */
  for (iWin=WM__FirstWin; iWin !=0; ) {
    WM_Obj* pWin = WM_H2P(iWin);
    GUI_RECT r = *pRect;
    GUI__IntersectRect(&r, &pWin->Rect);
    /* Calculate which area is actually visible by subtracting the
       windows which are on top of this one */
    WM_InvalidateBWinAbs (iWin, &r);
    iWin = pWin->hNextLin;
  }
  WM_UNLOCK();
}


/*
  ********************************************************************
  *                                                                  *
  *              manage windows stack                                *
  *                                                                  *
  ********************************************************************
*/


/* Return index (handle) of the window which is bottom of stack.
   Note that in the current implementation, this is always
   window 0.
*/
WM_HWIN WM_GetDesktopWindow(void) {
  return WM__FirstWin;
}

/*
  ********************************************************************
  *
  *              Create window (as child)
  *
  ********************************************************************
*/

WM_HWIN WM_CreateWindowAsChild(
                    int x0, int y0, int width, int height
                   ,WM_HWIN hParent, U16 Style, WM_CALLBACK* cb
                   ,int NumExtraBytes)
{
  WM_Obj* pWin;
  WM_HWIN hWin;
  WM_LOCK();
  Style |= WM__CreateFlags;
  /* Get Parent info */
  if (!hParent) {
    if (WM__NumWindows) {
      hParent = WM_HBKWIN;
    }
  }
  if (hParent) {
    GUI_RECT Rect;
//    Rect = WM_H2P(hParent)->Rect;

    WM_GetInsideRect(hParent, &Rect);
    WM__Client2Screen(WM_H2P(hParent), &Rect);

    x0 += Rect.x0;
    y0 += Rect.y0;
    if (width==0)
      width = Rect.x1-Rect.x0+1;
    if (height==0)
      height = Rect.y1-Rect.y0+1;
  }
  if ((hWin = (WM_HWIN) WM_ALLOC(NumExtraBytes+sizeof(WM_Obj))) == 0) {
    GUI_DEBUG_ERROROUT("WM_CreateWindow: No memory to create window");
  } else {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产91清纯白嫩初高中在线观看| 91久久免费观看| 成人国产精品免费观看动漫| 欧美在线观看一二区| 国产精品视频观看| 欧美一区二区三区在线观看 | 欧美三级日韩三级国产三级| 国产精品久久一级| 日本亚洲最大的色成网站www| www.日本不卡| 久久久久免费观看| 六月丁香婷婷色狠狠久久| 色哟哟精品一区| 国产精品你懂的| 国产乱人伦偷精品视频不卡| 制服丝袜中文字幕一区| 亚洲一区二区偷拍精品| 国产91精品一区二区| 久久一区二区三区四区| 捆绑紧缚一区二区三区视频| 欧美日韩午夜在线| 亚洲精品老司机| 中文字幕第一区第二区| 日韩成人免费电影| 色婷婷狠狠综合| 18成人在线观看| 成人a级免费电影| 亚洲国产精品成人综合色在线婷婷| 老司机精品视频线观看86| 国产香蕉久久精品综合网| 麻豆精品视频在线| 日韩一区二区精品| 奇米影视一区二区三区| 91精品国产色综合久久ai换脸| 亚洲国产综合在线| 欧美午夜在线一二页| 性做久久久久久免费观看欧美| 欧洲一区二区av| 香蕉久久一区二区不卡无毒影院| 欧美性极品少妇| 亚洲成人1区2区| 日本一区二区三区高清不卡| 一本到不卡精品视频在线观看| 国产视频911| 国产成人av一区二区三区在线| 精品国产91九色蝌蚪| 麻豆精品一区二区综合av| 日韩欧美国产一区二区在线播放| 亚洲成a天堂v人片| 欧美大片一区二区| 粉嫩av一区二区三区在线播放| 国产清纯在线一区二区www| 成人一二三区视频| 日韩毛片视频在线看| 欧美亚洲一区二区在线观看| 丝袜诱惑制服诱惑色一区在线观看| 欧美一三区三区四区免费在线看 | 91网站最新地址| 亚洲精品综合在线| 欧美一卡二卡在线| 蜜桃久久久久久| 欧美色图12p| 六月丁香婷婷久久| 国产精品久99| 欧美理论电影在线| 国产精品小仙女| 一区二区三区欧美| 久久综合久久鬼色中文字| 成人激情免费视频| 日韩电影在线免费观看| 中文字幕av不卡| 91精品国产免费| 91视频xxxx| 韩国欧美国产一区| 亚洲福利一区二区三区| 337p粉嫩大胆噜噜噜噜噜91av| www.视频一区| 伦理电影国产精品| 亚洲国产视频直播| 国产精品沙发午睡系列990531| 91.com视频| 99国产精品视频免费观看| 另类成人小视频在线| 亚洲精品亚洲人成人网| 久久久久88色偷偷免费| 7799精品视频| 色综合激情五月| 成人小视频免费观看| 免费看黄色91| 亚洲大片精品永久免费| 国产精品国产三级国产aⅴ原创| 日韩一级高清毛片| 欧洲国内综合视频| 不卡电影免费在线播放一区| 九色综合国产一区二区三区| 一区二区三区高清不卡| 国产精品久久久久影院亚瑟 | 色老汉一区二区三区| 国产不卡视频一区| 国产精品自产自拍| 美女网站色91| 青青草国产成人av片免费 | 亚洲视频电影在线| 国产欧美精品日韩区二区麻豆天美| 日韩一区二区三免费高清| 欧美日本一区二区三区| 欧美丝袜自拍制服另类| 在线免费观看日本一区| 91免费视频网址| 日本韩国一区二区三区视频| 99re这里只有精品首页| 91色综合久久久久婷婷| 精品99999| 制服丝袜亚洲播放| 91精品国产日韩91久久久久久| 8v天堂国产在线一区二区| 51精品视频一区二区三区| 91麻豆精品国产91久久久久久久久| 欧美日韩一卡二卡三卡 | 欧美在线不卡一区| 欧美午夜电影网| 色狠狠桃花综合| 欧美日韩一二区| 欧美一区二区三区视频| 精品精品国产高清a毛片牛牛| 欧美精品一区二区在线观看| 久久新电视剧免费观看| 日本一区二区高清| 亚洲免费观看高清| 亚洲一区二区三区中文字幕| 午夜av一区二区| 久久精品国产久精国产| 国产99久久久久| 色综合天天狠狠| 欧美美女直播网站| 精品剧情在线观看| 国产精品视频第一区| 亚洲午夜在线视频| 青娱乐精品视频在线| 国产福利91精品| 在线一区二区观看| 欧美一区二区私人影院日本| 久久亚洲综合色一区二区三区| 国产精品视频yy9299一区| 亚洲图片有声小说| 精品午夜久久福利影院| 国精产品一区一区三区mba桃花| 国产精品一卡二| 国产精品初高中害羞小美女文 | 久久精品夜色噜噜亚洲aⅴ| 亚洲国产成人私人影院tom| 一区二区三区精品久久久| 九一久久久久久| 欧美私模裸体表演在线观看| 久久综合99re88久久爱| 一二三四社区欧美黄| 精久久久久久久久久久| 欧美午夜精品久久久久久孕妇| 精品电影一区二区三区| 伊人一区二区三区| 国产美女主播视频一区| 在线亚洲欧美专区二区| 久久久久久**毛片大全| 日日嗨av一区二区三区四区| 成人免费视频播放| 日韩女同互慰一区二区| 一区二区三区电影在线播| 成人在线视频一区二区| 欧美一区二区三区在线观看视频| 国产精品久久久久久妇女6080| 日本午夜一本久久久综合| 91在线国内视频| 久久久午夜精品理论片中文字幕| 亚洲国产一区二区三区青草影视| 成人性色生活片| 2023国产精华国产精品| 天天影视涩香欲综合网| 91年精品国产| 最新日韩在线视频| 国产福利一区二区| 精品国产髙清在线看国产毛片| 亚洲国产欧美一区二区三区丁香婷| 丁香六月久久综合狠狠色| 精品国产第一区二区三区观看体验| 午夜不卡在线视频| 欧美日韩精品久久久| 一二三四社区欧美黄| 一本久久综合亚洲鲁鲁五月天 | 91免费看视频| 国产精品久久久久久久久快鸭 | 视频一区中文字幕国产| 在线看国产日韩| 亚洲免费看黄网站| 色噜噜夜夜夜综合网| 中文字幕亚洲一区二区av在线| 国产成人av电影免费在线观看| 精品久久久久久久一区二区蜜臀| 奇米影视一区二区三区小说| 日韩欧美一级二级| 黑人巨大精品欧美一区|