<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def on_update_page_links(self, evt):
 """ Perform PDF update of changed links."""

        if not self.update_links:                 # skip if unsupported links
            evt.Skip()
            return
        pg = self.doc[getint(self.TextToPage.Value) -1]
        for i in range(len(self.page_links)):
            l = self.page_links[i]
            if l.get("update", False):            # "update" must be True
                if l["xref"] == 0:                # no xref => new link
                    pg.insertLink(l)
                elif l["kind"] < 1 or l["kind"] > len(self.linkTypeStrings):
                    pg.deleteLink(l)              # delete invalid link
                else:
                    pg.updateLink(l)              # else link update
            l["update"] = False                   # reset update indicator
            self.page_links[i] = l                # update list of page links
        self.btn_Update.Disable()                 # disable update button
        self.t_Update.Label = ""                  # and its message
        self.btn_Save.Enable()
        self.t_Save.Label = "There are changes. Press to save them to file."
        evt.Skip()
        return