home *** CD-ROM | disk | FTP | other *** search
- property sp
- global currentMember, pointClicked, wordNum, wordText2, wordText
-
- on mouseUp me
- wordText = currentMember.word[wordNum]
- if wordText contains "@" then
- gotoNetPage("mailto:" & wordText)
- else
- nothing()
- end if
- if wordText.char[1..7] = "http://" then
- gotoNetPage(wordText)
- else
- nothing()
- end if
- if wordText.char[1..8] = "https://" then
- gotoNetPage(wordText)
- else
- nothing()
- end if
- if wordText.char[1..4] = "www." then
- gotoNetPage("http://" & wordText)
- else
- nothing()
- end if
- end
-
- on beginSprite me
- sp = sprite(me.spriteNum)
- pFormat()
- end
-
- on pFormat me
- t = sp.member
- repeat with i = 1 to t.word.count
- if (t.word[i].char[1..7] = "http://") or (t.word[i] contains "@") or (t.word[i].char[1..4] = "www.") or (t.word[i].char[1..8] = "https://") then
- t.word[i].color = rgb(255, 255, 255)
- t.word[i].fontStyle = [#plain, #underline]
- end if
- end repeat
- end
-
- on mouseWithin me
- pointClicked = the mouseLoc
- currentMember = sprite(me.spriteNum).member
- wordNum = sprite(me.spriteNum).pointToWord(pointClicked)
- if wordNum <> -1 then
- wordText2 = currentMember.word[wordNum]
- if (wordText2.char[1..7] = "http://") or (wordText2 contains "@") or (wordText2.char[1..4] = "www.") or (wordText2.char[1..8] = "https://") then
- cursor(280)
- else
- cursor(-1)
- end if
- end if
- end
-
- on mouseLeave
- cursor(-1)
- end
-